How create a rope in chipmunk?

Official forum for the Chipmunk2D Physics Library.

How create a rope in chipmunk?

Postby MetalSoul » Wed Jul 31, 2013 12:48 pm

Hello

I am new to chipmunk, and i want learn more about

I think chipmunk will be the physics engine for my game

Now , i want know, how i can create rope ( smooth rope )
Any simple code? For iphone dev and cocos2d

I tried find in google but there nothing about chipmunk,, why

You guys should create tutorials for us, thats will let any one can understand and buy pro version

Thats all and thanks in advance
MetalSoul
 
Posts: 2
Joined: Tue Jul 30, 2013 7:08 pm

Re: How create a rope in chipmunk?

Postby slembcke » Wed Jul 31, 2013 2:49 pm

We have a number of tutorials on the website here: http://chipmunk-physics.net/documentation.php

We don't have one specifically for rope and Cocos2D, but it's not difficult to do. You just need to attach a bunch of small bodies together with joints. The harder part is drawing nice ropes, which depends heavily on what sprite engine you want to use.

Since Chipmunk is a rigid body physics library, it's not idea for rope simulation. You could make more stable looking, and higher performance rope using vertlet integration and simple distance constraints. Read this paper by Thomas Jakobsen for more info: http://www.pagines.ma1.upc.edu/~susin/f ... hysics.pdf It's quite simple to implement.
Can't sleep... Chipmunks will eat me...
Check out our latest projects! -> http://howlingmoonsoftware.com/wordpress/
User avatar
slembcke
Site Admin
 
Posts: 4164
Joined: Tue Aug 14, 2007 7:13 pm

Re: How create a rope in chipmunk?

Postby MetalSoul » Fri Aug 02, 2013 8:58 am

Ahh, for now i don't need that maybe in future

Thanks for support
MetalSoul
 
Posts: 2
Joined: Tue Jul 30, 2013 7:08 pm

Re: How create a rope in chipmunk?

Postby yomanx » Fri Dec 19, 2014 7:50 pm

Hi to all,

I did it "You just need to attach a bunch of small bodies together with joints."

But when it collision with objects, the joint stretch, how can i fix it?

i used sPivotJoint
yomanx
 
Posts: 7
Joined: Fri Dec 19, 2014 6:17 pm

Re: How create a rope in chipmunk?

Postby sortris » Mon Dec 22, 2014 5:16 am

Maybe make the bodies sensonrs?
body.setSensor(true)
After then they won't collide with other objects.
sortris
 
Posts: 4
Joined: Mon Oct 21, 2013 8:34 am

Re: How create a rope in chipmunk?

Postby yomanx » Sun Dec 28, 2014 9:32 am

yeah, some little better then nothing..
yomanx
 
Posts: 7
Joined: Fri Dec 19, 2014 6:17 pm


Return to Chipmunk2D Physics

Who is online

Users browsing this forum: No registered users and 4 guests

cron