Detecting collisions between bodies

Godot Version

4.5

Question

What I’m trying to do right now is detect when a VehicleBody3D “Grand Aerovan” is touching a StaticBody3D “Floor”, and print whether they are currently touching or not touching.

I am new to game development and don’t understand how to use signals, I get that body_entered needs to be used but don’t get how to use it properly. Do I need to use collision layers too?

Any help is appreciated!

Check this article that explains what signals are and how to use them:

Once you finish that article and try the examples posted there, try to rewrite your original code and see if you can fix the issue with your new knowledge.

2 Likes

How come? It might be helpful to describe what you’re actually trying to do, because that is a very low-level thing that TBH isn’t super useful on its own. It’s possible that there is a better solution for whatever end point you’re trying to get to by doing this detection.

1 Like