Jump to content
  • Advertisement
Sign in to follow this  
Odion

Player follow as seen in Donkey Kong Country 2

This topic is 696 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I am trying to figure out the simplest solution to do a Donkey Kong Country 2 -like player follow.

Here is a video of what I mean. The way Diddie follows Dixie.

 

 

 

Does anyone have any idea how to achieve this the most simple, clever way? Replicating player movement input is not good enough, because of moving platforms, and interaction with the world that can change the main player position and velocity.

 

Thank you in advance! 

Share this post


Link to post
Share on other sites
Advertisement

Replicate player movements while also adding pushing the follower towards the player, based on distance, and stop replicating player movements if within a certain distance?

 

This way the follower will do what the player does, but just a little bit faster, and if the player jumps on a platform/gets away from the follower, it will correct itself mid-jump to make sure it reaches the player.

 

I'd suggest downloading an editor for it, and trying to reproduce edge cases to see how they handled it

 

http://www.dkc-atlas.com/forum/viewtopic.php?f=37&t=1325

 

Maybe set cases where you follower can't follow, and see how it's resolved.

Share this post


Link to post
Share on other sites

That's a good idea. Btw how would you do the replicate player movement part? Collect the last few player input in an array, and feed these inputs to the follower with a delay?

Share this post


Link to post
Share on other sites

Looks like it's got a few techniques that it's delegating to based on distance from the player character. If it's too close it backs away slowly, if it's slightly too far then it plays back recorded player positions, if it's significantly far then it just approaches the player as quickly as possible.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!