Attention | Topic was automatically imported from the old Question2Answer platform. | |
Asked By | Neosss |
I want to press a button to set the value of a variable in other script and and execute an order on depending on the value it returns.
For this I have used the following script
player.gd
var difficulty = get_node(“HUD”).get(“NormalMode”).difficulty
But Godot says: Node not found: HUD.
I try with other paths like (“Main/HUD”), (“root/Main/Hud”), (“/root/Main/Hud”), (“/Main/Hud”), (“…/HUD”), (“/HUD”).
But always says that the node cannot be found or that absolute paths cannot be used
What it’s wrong?
I must say that I have the exact same route Nodes as in the example game Dodge the Creeps