ChipmunkMultiGrab problem

Official forum for the Chipmunk2D Physics Library.
Post Reply
Demos
Posts: 6
Joined: Mon Jul 09, 2012 2:40 am
Contact:

ChipmunkMultiGrab problem

Post by Demos »

Hi! I have this code in init method:

1: multiGrab = [[ChipmunkMultiGrab alloc] initForSpace:space withSmoothing:cpfpow(0.8, 60.0) withGrabForce:1000];
2: multiGrab.layers = GRABABLE_LAYER;
3: multiGrab.grabRotaryFriction = 100;

Programm crashes after line 3. I have no idea what's the reason. Could you help me?

PS: I have iOS 6 beta 2 and XCode 4.5
User avatar
slembcke
Site Admin
Posts: 4166
Joined: Tue Aug 14, 2007 7:13 pm
Contact:

Re: ChipmunkMultiGrab problem

Post by slembcke »

Can you give any more information about the crash? What kind of crash was it? What does the debugger/log say?

layers and grabRotaryFriction are both just simple synthesized properties. There isn't really a reason why one should crash and the other wouldn't.
Can't sleep... Chipmunks will eat me...
Check out our latest projects! -> http://howlingmoonsoftware.com/wordpress/
Demos
Posts: 6
Joined: Mon Jul 09, 2012 2:40 am
Contact:

Re: ChipmunkMultiGrab problem

Post by Demos »

-[ChipmunkMultiGrab setGrabRotaryFriction:]: unrecognized selector sent to instance 0x1edee0d0

The same problem with setGrabFriction, setGrabRadius and getters for these methods.
User avatar
slembcke
Site Admin
Posts: 4166
Joined: Tue Aug 14, 2007 7:13 pm
Contact:

Re: ChipmunkMultiGrab problem

Post by slembcke »

What version do you have? The push mode and rotary friction was added in 6.1.0.
Can't sleep... Chipmunks will eat me...
Check out our latest projects! -> http://howlingmoonsoftware.com/wordpress/
Demos
Posts: 6
Joined: Mon Jul 09, 2012 2:40 am
Contact:

Re: ChipmunkMultiGrab problem

Post by Demos »

I have last version: Chipmunk Pro 6.1.1 trial
User avatar
slembcke
Site Admin
Posts: 4166
Joined: Tue Aug 14, 2007 7:13 pm
Contact:

Re: ChipmunkMultiGrab problem

Post by slembcke »

Hmm. Something is definitely messed up with the build (or download link on the website?). I just got another similar bug about this last night.

I have a deadline that I need to make for a contract project tonight, but will look at this first thing tomorrow morning.
Can't sleep... Chipmunks will eat me...
Check out our latest projects! -> http://howlingmoonsoftware.com/wordpress/
User avatar
slembcke
Site Admin
Posts: 4166
Joined: Tue Aug 14, 2007 7:13 pm
Contact:

Re: ChipmunkMultiGrab problem

Post by slembcke »

Ok. Sorry about the delay. I worked out the issue with the other person having troubles. It turns out he had two copies of the library code in the project, so it was linking to an older version and causing weird issues.

I checked a fresh download of the Chipmunk Pro 6.1.1 trial from the website and was unable to reproduce the issue. The method signature shows up in the symbol dump of the library as well for both armv6 and armv7 architectures. So I'm not quite sure what your issue could be.

Is it possible that you have a duplicate as well? The linker simply picks the first one it can find when searching the library paths. Just to be sure, try removing all of the Chipmunk library code from your project (including the header and library search paths in the target build settings). It shouldn't compile at this point unless it's finding a library hiding somewhere else in your project. Then download a fresh copy of the 6.1.1 trial and re-adding it.

Other than that, I'm not sure what the issue could be.
Can't sleep... Chipmunks will eat me...
Check out our latest projects! -> http://howlingmoonsoftware.com/wordpress/
Demos
Posts: 6
Joined: Mon Jul 09, 2012 2:40 am
Contact:

Re: ChipmunkMultiGrab problem

Post by Demos »

slembcke wrote:Ok. Sorry about the delay. I worked out the issue with the other person having troubles. It turns out he had two copies of the library code in the project, so it was linking to an older version and causing weird issues.

I checked a fresh download of the Chipmunk Pro 6.1.1 trial from the website and was unable to reproduce the issue. The method signature shows up in the symbol dump of the library as well for both armv6 and armv7 architectures. So I'm not quite sure what your issue could be.

Is it possible that you have a duplicate as well? The linker simply picks the first one it can find when searching the library paths. Just to be sure, try removing all of the Chipmunk library code from your project (including the header and library search paths in the target build settings). It shouldn't compile at this point unless it's finding a library hiding somewhere else in your project. Then download a fresh copy of the 6.1.1 trial and re-adding it.

Other than that, I'm not sure what the issue could be.
Thank you very much. It helped me.
Post Reply

Who is online

Users browsing this forum: No registered users and 23 guests