No game_over statement (I read godot docs)

Godot Version

4.5

Question

I was following the godot docs and making dodge the creeps, and was going to move on to the next lesson, ui, but i decided to test my game. through my tests, im pretty sure the “game_over“ statement didn’t activate. this message pops up as a warning: Missing connected method ‘_game_over’ for signal ‘hit’ from node ‘Main/PLAYER’ to node ‘Main’

can anyone suggest what happened?

It seems like you don’t have a “_game_over” function.

When you’re connecting signals from a node to a script that script will automatically have function created for that signal.

Your signal is connected to a script using method “_game_over”. It seems like that same script don’t have that method. Yet at the same time the connection is still exists between the signal and the script.

If in your script you have method with the name “game_over” then rename it into “_game_over”.

Read the errors carefully. They usually really well written so it’s always easy to understand what’s the problem is