Ledge climb animation and movement (2d platformer)

Started by
0 comments, last by Eck 8 years, 4 months ago
What is the best way to go about this without it getting overly complex?

So far I understand (hobbyist here not a pro) there a few options including:

1. Apply controlled force to the rigid body on the y axis until the root position is just above the hand position then apply enough force on the x axis so as the character is standing on the platform. At the same time somehow sync this with the climb animation(s).

Remarks: movement is easy here and can even be controlled by a prismatic sliding joint but I'm unsure of how I would keep the animations (spine) in sync with the movement.

2. Root motion animation that drives the root position of the character. Teleport the rigid body when complete and hope box2d can still properly respond in time to any collision if any objects happen to fall from the sky.

Remarks: sounds easier to actually animate but not sure if I'll run into any problems with the spine runtime, box2d or later down the line moving platforms and varied height platforms.

3. Apply IK constraint programmatically on the hands to lock them in place and proceed to rotate the bones manually or apply small preset (few keys/frames) animations whilst applying the needed force to the rigid body at the same time.

Remarks: seems like this would give maximum control to the player but it sounds way to complicated for me to implement at my level, not exactly sure where I would start.

4. Move the rigid body to desired location but dont update model. Let animation move model to root position (desired position)

Remarks: simple but just doesnt feel right and how would i handle climbing onto uneven surfaces?

Thanks in advance for any input!

FYI: This is an ECS (libgdx + ashley) based engine with box2d. The ledge grab is already implemented as a separate system so we can assume here that the character is already capable of hanging from a ledge of any height.
Advertisement
Aardvajk just got done showing this off in a developer journal.

http://www.gamedev.net/blog/515/entry-2261661-edge-grabbing/

Maybe ask him for some pointers?

- Eck

EckTech Games - Games and Unity Assets I'm working on
Still Flying - My GameDev journal
The Shilwulf Dynasty - Campaign notes for my Rogue Trader RPG

This topic is closed to new replies.

Advertisement