I hadn't coded much OO before now, and my game is getting pretty big and when coding in methods its sometimes confusing what word is the instance's field or if its a global or a local of the method(). So I started using "Self." before each field in each method but that was annoying and there was no guarantee that I remember to put that.
I saw some code that used underscores for fields of a type, and that code looked really scary to me do I didn't do that. I'm wondering whats the best way to do this? What does it mean if there is a underscore after the word? What about 2 underscores, I think I've seen that too.
What if fields required a "." before their name, when coding in methods? Wouldn't that be a good way to solve this problem? Of course I can't make the preprocessor work like that, but I was just wondering.
I saw some code that used underscores for fields of a type, and that code looked really scary to me do I didn't do that. I'm wondering whats the best way to do this? What does it mean if there is a underscore after the word? What about 2 underscores, I think I've seen that too.
What if fields required a "." before their name, when coding in methods? Wouldn't that be a good way to solve this problem? Of course I can't make the preprocessor work like that, but I was just wondering.