Jump to content

  • Log In with Google      Sign In   
  • Create Account

Formula / class for creating a rope for 2D side scroller


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
2 replies to this topic

#1 DarkRonin   Members   -  Reputation: 616

Like
0Likes
Like

Posted 29 July 2013 - 06:20 PM

Hi Guys,

 

Does anyone know of a formula / class for creating a rope for 2D side scroller.

 

Ideally I would like to create something like the rope used in Limbo, where it reacts to physics etc.

 

Any help would be awesome. :)

 



Sponsor:

#2 Paradigm Shifter   Crossbones+   -  Reputation: 5436

Like
1Likes
Like

Posted 29 July 2013 - 06:48 PM

Well the formula would be

 

Force = mass * acceleration

 

or

 

F = ma

 

;)

 

You can model a rope as a series of point masses constrained by fixed distances between them. You'd probably be better checking out a physics library though. They used Box2D for angry birds, that should be good for a 2d game, http://en.wikipedia.org/wiki/Box2D


"Most people think, great God will come from the sky, take away everything, and make everybody feel high" - Bob Marley

#3 DarkRonin   Members   -  Reputation: 616

Like
0Likes
Like

Posted 29 July 2013 - 07:36 PM

Thanks man! I'll check out Box2D :)






Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS