How to make an elastic rope just like cut the rope game

Discuss issues specific to miscellaneous ports of Box2D
speedboy
Posts: 9
Joined: Sun Apr 15, 2012 8:39 pm

How to make an elastic rope just like cut the rope game

Postby speedboy » Mon Apr 16, 2012 10:45 pm

This is my code .Can anyone help me?
Attachments
ElasticRope.h
source code
(7.11 KiB) Downloaded 726 times

irresistible force
Posts: 1991
Joined: Tue Jun 24, 2008 8:25 pm
Location: Tokyo
Contact:

Re: How to make an elastic rope just like cut the rope game

Postby irresistible force » Tue Apr 17, 2012 2:56 am

Help you what? Be more specific.

BoxMan
Posts: 11
Joined: Fri Feb 10, 2012 4:08 am

Re: How to make an elastic rope just like cut the rope game

Postby BoxMan » Tue Apr 17, 2012 10:56 am

Well the topic does say "How to make an elastic rope just like cut the rope game" ...

speedboy
Posts: 9
Joined: Sun Apr 15, 2012 8:39 pm

Re: How to make an elastic rope just like cut the rope game

Postby speedboy » Wed Apr 18, 2012 8:16 pm

irresistible force wrote:Help you what? Be more specific.


When I pull the rope is long, each rigid body will shake, not in a straight line. Can anyone provide advice, preferably attached some code, Thank you very much.
following is elastic rope of cut the rope game:
Attachments
images.jpg
images.jpg (6.55 KiB) Viewed 8262 times

jayther
Posts: 266
Joined: Sun Oct 25, 2009 3:28 am
Contact:

Re: How to make an elastic rope just like cut the rope game

Postby jayther » Thu Apr 19, 2012 12:05 am

You should try adding a distance joint at the ends of the rope so it won't do that shaking segments thing when stretched.

speedboy
Posts: 9
Joined: Sun Apr 15, 2012 8:39 pm

Re: How to make an elastic rope just like cut the rope game

Postby speedboy » Thu Apr 19, 2012 1:43 am

jayther wrote:You should try adding a distance joint at the ends of the rope so it won't do that shaking segments thing when stretched.


Good idea, I will try ,thank you very much

speedboy
Posts: 9
Joined: Sun Apr 15, 2012 8:39 pm

Re: How to make an elastic rope just like cut the rope game

Postby speedboy » Thu Apr 19, 2012 9:15 am

I successfully make an elastic rope with b2DistanceJoint. Reference to the example of box2D the web. Thank you to those friends who give me advice.
Attachments
iOS 模拟器屏幕快照“Apr 20, 2012 12.15.12 AM”.png
iOS 模拟器屏幕快照“Apr 20, 2012 12.15.12 AM”.png (10.9 KiB) Viewed 8248 times

jaydn
Posts: 2
Joined: Tue Dec 06, 2011 11:00 pm

Re: How to make an elastic rope just like cut the rope game

Postby jaydn » Wed May 30, 2012 4:37 pm

speedboy wrote:I successfully make an elastic rope with b2DistanceJoint. Reference to the example of box2D the web. Thank you to those friends who give me advice.


Can you give me link to "example of box2D the web" you mentioned above?


Return to “Miscellaneous”



Who is online

Users browsing this forum: No registered users and 3 guests