Page 1 of 1

Interrupting MoveTo on Collision / Player Death / etc...

PostPosted: Thu Jan 12, 2006 7:30 pm
by fauldran
Scenario:
I have a player character that you move using the mouse/stylus. Tap the ground he tries to walk to that point. I’m using physical response to keep the player from walking through walls. All that is working great.
Its an isometric perspective.

Question:
The player is animated by choosing an animation when MoveTo is executed (walk animation) and then choosing another animation in the Move Finish event (idle animation).

How do I interrupt the MoveTo when a collision occurs and return the player to his idle animation (by way of the Move Finish event)?

Possible Solutions:
I have tried executing another MoveTo when a collision occurs that tells the player to move to the players current position. This always causes the player to get “stuck” in the wall though.

I have also tried using To Anterior Position but I am not sure that I understand exactly how that works. I run into the same problems with it. The player either gets stuck in the wall or can be forced through the wall.

Some kind of sliding collision would be a great feature of GE.

PostPosted: Fri Jan 13, 2006 4:18 pm
by makslane
Tr Move To with this options:

Actor: player
Relative to: player
Position: 0, 0
Velocity: 1

PostPosted: Sat Jan 14, 2006 8:33 pm
by fauldran
That seems to work fine. Thanks.