Godot Version
Question
Hi guys. I am not a programmer, so please ELI 5. I have attached a screenshot to help.
This is the standard “your first 3dgame” script for the mobs.
I have an error in line 15, but I am unsure where it has gone wrong. The line is
“mob_spawn_location.progress_ratio = randf()”
and the error is: “Invalid Set index progress_ratio ( on base null instance) with value type float”
What is this error message trying to say? I’m stuck
The program thinks your your mob_spawn_location
is nothing, as in: it is an empty variable.
Where it says get_node("SpawnPath/SpawnLocation")
, change it to get_node("SpawnPath/Spawnlocation")
(with a lowercase L). Alternatively, rename your Spawnlocation node in the scene tree to SpawnLocation.
Right now your get_node line is failing because it cannot find the SpawnLocation node.
1 Like
I really appreciate you snipercup, thanks
You explained it in an easy to understand way. I’ll fix it up when I get home from work. Have a great day
Update: Its working.
Very simply this was just a problem with being case sensitive
the code cared very much about SpawnPath being labelled Spawnpath
1 Like