Hi,
I have two objects that need to be able to collide with eachother, or for LUA to know if they collide, but I don’t want the objects spinning and turning as it does when it’s set to dynamic (physics body).
I want the item to behave like a kinematic object that is being dragged i.e. it goes up, down, left and right and over the other object but that it also detects collisions.
Here it says:
http://developer.coronalabs.com/content/game-edition-physics-bodies
- static bodies don’t move, and don’t interact with each other; examples of static objects would include the ground, or the walls of a pinball machine.
- dynamic bodies are affected by gravity and collisions with the other body types.
- kinematic objects are like static bodies, but they can be moved and are affected by forces but not by gravity, so you should generally set draggable objects to “kinematic”, at least for the duration of the drag event
So how do I do if I want to kinematic bodies to detect a collision?
Best regards,
Tomas