kinematic object as Area2d?

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

In unity you create an object, add a rigidbody or not and a collider, with onCollisionEnter you can detect if another collider is touching your object. Godot has signals, area2D or area.
And that’s where I don’t get it… since Godot does not have an “onCollision/TriggerEnter” etc, I have to create an Area2D as a child of my kinematic object, duplicate the collision, make it slightly larger, change collision mask and layer and set it as a child of the Area2D, which seems like a rather ugly way to do it and a waste of an already existing collider.I mean this does not look right at all…
enter image description here

:bust_in_silhouette: Reply From: skysphr

Kinematic bodies typically detect collision by using the KinematicCollision2D object returned by movement functions. See this page for more details.