I am a beginner in Godot game engine. I'm trying to make a platformer game that uses cards as a skill system. I want to enable the skill whenever the card is put or hovered around the player's sprite. However, I am getting stuck in this problem that I can't make my card detect the player when I hover the card around the player. I've tried to use the body_entered signal, but nothing happens, I tried to print something in the signal function to test whether the signal is working but the it prints nothing so it means the signal is not working.
Asked
Active
Viewed 119 times
0
-
What is your "card", and where is this signal that is not working? Does this help: https://stackoverflow.com/a/69731270/402022 ? – Theraot Nov 29 '21 at 17:05
-
Please provide enough code so others can better understand or reproduce the problem. – Community Dec 05 '21 at 12:03
1 Answers
0
try setting the position of the card to the position of the mouse, then under CollisionObject2D theres a signal called "mouse_entered()", which you can use to check if the mouse entered the player's collision

blepis
- 13
- 6