I’d recommend going through the physics tutorial here.
This depends a lot on what you’re trying to do. There are three main physics body types in Godot: KinematicBody, RigidBody and StaticBody. These are implemented as nodes. Further, they need a Collision object as a direct child node to define the shape of the physics bodies (CollisionPollygon2D in your case).
Now, collision reporting can be very expensive so generally speaking, RigidBody and StaticBody physics controllers do not report collisions. You can change this by increasing the number of contacts reported in the properties of your StaticBody or RigidBody node.
You can find a handy chart indicating who has access to what information in a collision here.
As for getting information reported to StaticBody2D, here’s a rule of thumb: Don’t.
I am currently trying to detect collision in a RigidBody2D , but it is divided into two parts, the bottom and the top , I need to detect which of these parts occurred the collision. I already detected a collision using the body_enter signal , but it seems that does not help me with the condition cited above
Johnz | 2016-02-27 19:16
Hi!
Thanks for your answer.
It seems that the link you provide here is not available anymore:
You can find a handy chart indicating who has access to what information in a collision here.
At least I did not see it on DDG in the free search.