The first step of the ShadowMovementV2 was to take only the essential parts of the code and fix the problems present in version 1:
- Firstly its ray system was changed to match the diagram above, alongside this the rays range is now used to set its movement speed.
Side by Side, Broken Movement, Fixed Movement
- Secondly the ShadowMovement object is set to always face it’s movement direction, no strafing. This is because there were errors when entering a new orientation from the left or right, by making its movement direction run by a external reference transform, and having the objects actual forward direction be facing the move direction, this problem was solved.