Difference between revisions of "Talk:MoveTo"

Jump to navigation Jump to search
6 bytes added ,  18:40, 22 February 2009
m
imported>Khnum666
m (Typos)
imported>QQuix
Line 92: Line 92:
It seems that instead of "acting as a return" the MoveTo function crashes the script AFTER moving the player or, somehow, prevents the script from complete successfully. The game engine seems to notice that the block did not complete successfully and tries to run it again the next frame. The Player will be moved again. The script will crash again, etc, etc. Final result: the player is moved to the same spot every frame - cannot move from there. This crash effect may be related to the fact that the scripted object is moved with the player as it does not occur in an OnDrop block or if the object is added to an NPC/container (in both cases, the object stays behind and is not moved with the player)
It seems that instead of "acting as a return" the MoveTo function crashes the script AFTER moving the player or, somehow, prevents the script from complete successfully. The game engine seems to notice that the block did not complete successfully and tries to run it again the next frame. The Player will be moved again. The script will crash again, etc, etc. Final result: the player is moved to the same spot every frame - cannot move from there. This crash effect may be related to the fact that the scripted object is moved with the player as it does not occur in an OnDrop block or if the object is added to an NPC/container (in both cases, the object stays behind and is not moved with the player)


Workarounds: (1) add controls to prevent the MoveTo function to run two frames in a row or (2) Move the Moveto function to another block or another script.
Workarounds: (1) add controls to prevent the MoveTo function from running two frames in a row or (2) Move the Moveto function to another block or another script.


Obs: PositionCell does not have this problem.  [[User:QQuix|QQuix]] 11:36, 22 February 2009 (EST)
Obs: PositionCell does not have this problem.  [[User:QQuix|QQuix]] 11:36, 22 February 2009 (EST)
Anonymous user

Navigation menu