Welcome to the forums @Hopeijay!
How are you moving the character? If you are using move_and_collide
, collision information will be returned by the function: collision_info = mode_and_collide(velocity)
, where the collision info is a KinematicCollision2D (for 3D it's a KinematicCollision3D). If you are using move_and_slide, you will need to use get_slide_collision
(documentation), which will hold any collision data retrieved from move_and_slide
.
Though in most of my projects, I just use an Area2D node with a collision shape slightly larger than the KinematicBody2D's collision shape, and use it to detect collisions. It works pretty well, and because its an Area2D, you can use the body_entered/body_exited
signals when collisions occur.