Skip to content

Commit

Permalink
Fix for the missing last call to updatePosition() when tweenPosition … (
Browse files Browse the repository at this point in the history
#12)

* Fix for the missing last call to updatePosition() when tweenPosition has reached 1.

* Fix for the missing last call to updatePosition() when tweenPosition has reached 1.

- Just update the position on setProperty

* Fix for the missing last call to updatePosition() when tweenPosition has reached 1.

- Position also needs to be updated when tweening x and y.

---------

Co-authored-by: Nikolas Banspach <[email protected]>
  • Loading branch information
NickBanspach and Nikolas Banspach authored Feb 14, 2023
1 parent b97585c commit 4005aee
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions src/motion/actuators/TransformAroundPointActuator.hx
Original file line number Diff line number Diff line change
Expand Up @@ -79,14 +79,7 @@ class TransformAroundPointActuator<U> extends SimpleActuator<DisplayObject, U> {
} else {
super.setProperty(details, value);
}
}

private override function update(currentTime:Float) {
super.update(currentTime);

if (active && !paused) {
updatePosition();
}
updatePosition();
}

private inline function getTransformedPoint(result:Point):Void {
Expand Down

0 comments on commit 4005aee

Please sign in to comment.