Actor.SetX/Y and Actor.MoveTo bug in init override

niccosw

  • Posts: 91
When using the init function, Actor.MoveTo will overwrite previously set Actor.SetX/Y values. This happens with the code blocks as well. This is not occurring with other tweening functions like Actor.SpinTo.

It is possible to correct the problem using a runLater / "do after <sec> seconds" time delay.


Epic428

  • Posts: 1118
I'm not sure I understand the bug here. When you "slide" the actor, the actor should have a new x/y position should it not? The only problem with sliding, it ignores collisions.
James Moore - Official Support & Documentation.
We cannot and will not respond to PM's asking questions. Please make a new thread in the forums if you have any questions, Thank you.
For better support and faster response times, please post your logs regarding any Stencyl related issues. Debug > Logs > Generate Logs

niccosw

  • Posts: 91
To recreate the bug, do the following steps:

1) Create a new scene and an actor
2) Create an actor behavior
3) Include the steps in my example photo: Set x:100, Set y:100, Spin 360, slide to x/y:300/300. The durations don't matter.
4) Place the actor in the scene somewhere off to the right (x:300, y:100)
5) Run the game

What should happen: The actor's position is moved to 100/100 and then begins a spin/slide to 300/300.

What actually happens: The actor remains in it's default position 300/100 and then begins a spin/slide to 300/300. The X/Y set to 100/100 is ignored.