Repackaging for pip, fixing of bugs.
Now supports movement states (properly).