|Topic was automatically imported from the old Question2Answer platform.
If I want a Vector3 to be reset to all zeros every time I call _physics_process(delta), is it wasteful/inefficient to say
func _physics_process(delta): -> var x = Vector3.ZERO
Should I instead place var x = Vector3.ZERO in my member variables and then simply reset it each time?
I’m just trying to figure out the advantages and disadvantages of each!
I see the first option quite often, but something about creating a new one each time just doesn’t sit right with me. On the contrary, I’d rather not clutter up my member variables if I don’t need to.