I`m newbie in chipmunk.
Could you help me?
I tried to solve a simply problem myself, but unfortunately i can not find good solution.
The question "How to move a body(all physic laws have to be worked) on the screen(iphone) ?".
i have 10 poly objects(each object has equal mass).. i want to move a one body(touchesBegan,touchesMoved,touchesEnded)
I looked at all forum posts, i found only 2 types.
1. use force.
can not right calculate the force.
How can i calculate the force if the object moved on 10 pix?
I tried to calculate it using the following formula:
force = mass of the object*(distance[10 pixel]/dt*dt), but it seems wrong formula.
I want to do only one thing if i`m moving a finger on the screen the object has to move follow my finger at once.
2. write own velocity function likes cpMouse. - this way is not good for me, because gravity and other things do not take into account.
move to in chipmunk
- slembcke
- Site Admin
- Posts: 4166
- Joined: Tue Aug 14, 2007 7:13 pm
- Contact:
Re: move to in chipmunk
If you are willing to take the leap and try out the trunk version, I have mouse control implemented there. Copying that would be the easiest route.
Can't sleep... Chipmunks will eat me...
Check out our latest projects! -> http://howlingmoonsoftware.com/wordpress/
Check out our latest projects! -> http://howlingmoonsoftware.com/wordpress/
Who is online
Users browsing this forum: No registered users and 6 guests