Skip to content

Commit

Permalink
moveUp and moveDown action apply parent coordinate system +Y translat…
Browse files Browse the repository at this point in the history
…ion instead of local "up" (#1763)
  • Loading branch information
aclegg3 authored Jun 1, 2022
1 parent 5944ba2 commit a776e4f
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/esp/scene/ObjectControls.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,9 @@ SceneNode& moveLeft(SceneNode& object, float distance) {

SceneNode& moveUp(SceneNode& object, float distance) {
// TODO: this assumes no scale is applied
object.translateLocal(object.transformation().up() * distance);
// Note: this is not a body action and is applied to the sensor rather than
// the Agent, so it will move the sensor in Agent's +Y (up) direction
object.translate(Magnum::Vector3(0, 1, 0) * distance);
return object;
}

Expand Down

0 comments on commit a776e4f

Please sign in to comment.