Godot 4.2
I’m making a 2d side scrolling game and wanted to add a state machine into the game. So I started watching tutorials, but they were all gdscipt (I use c#) and I kept seeing people turning the script into custom nodes and figured out that in c# I can do the same thing by using GlobalClass. now here are my questions, is the only way to do this using GlobalClasses? If not, how could I do it? Is it bad to make too many GlobalClasses? Because I remember learning that too many global variables make the program slower so I was wondering if it is the same with these GlobalClass custom nodes. Is the most effective way to make a state machine for my case a node based finite state machine?
I appreciate any feedback and response, also let me know if any clarification is needed, thank you!