My GPS is just a script not a node, the
self.DecayHealth is an old habit from another programming language I got, and so far it did not do any harm in my codes, and yes, I don't need to call
self on that, it belongs to the node calling the function.
GPS.Health is defined on the ready of the GlobalPlayerStatus.gd as = 100, so it automatically becomes an integer right? Which is autoloaded, so I don't know how it becomes null?
And DecayHealth is also defined as variable onready of Node B same way, defined as = 0, my guess is that my function cannot retrieve the
Health from the GlobalPlayerStatus for some reason.
My idea was simply to create a function to alter values from the GlobalPlayerStatus, I plan to use this to control Stamina, Hunger, Thirsty and Oxygen bars. Maybe even later I can create buffs and debuffs.
What else could I try?