Is inside another Node event

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By UnitedCatdom

So I am working on my first 3D game and I can’t figure out how to create an is inside another node event. I am working on pickupEvent where player picks an item when walks into it. I just want to know how to send a signal or check if the item hitbox is inside Player node.

:bust_in_silhouette: Reply From: Inces

This is called collision. There are nodes specifically specialized to detect collisions, they are called Areas and Bodies. Add CollisionShape node to them and You will be able to set up range and properties of detection. New signal options will appear in inspector, being called _on_area_enetered, _on_body_entered and so on. Use them for your problem.

enter image description here

Something like this?

UnitedCatdom | 2021-12-04 10:35

Yes. Let Player and item br bodies/areas, and when one enters the others range of collision shape - this signal is emitted.

Inces | 2021-12-04 15:03