Hmm, fair enough. My main motivation for using 'this' is I mostly work with PHP, which has a huge library of global functions. So I'm used to having to identify class methods when calling them.
Next update, I'll work on removing 'this' from the method calls. I will keep them for variables though as I find a lot of value in being able to skim code and separate class properties from local variables.
As for the class variable placement, yeah, that was something I was experimenting with. You've got the "Principle of Proximity": keep related actions together (see Code Complete, 2ed, pg 351). That works a charm within routines, but I was trying to extend it to the class level: if a class variable is only used by one or two methods, group them all together.
I'm not sure it works though, so again, next update I'll try moving all the class variables to one place.
Cheers.
Thanks. :) Note that given I started writing this last night, the code structure is still evolving and there are a lot of 'magic numbers' floating around. Magic numbers are things that are hard-coded (for example, how much damage a hit does) that should be moved out to config files and constants.
2009/6/3
Othello
2009/6/3
RPG Sim
2009/6/2
RPG Sim
2009/6/2
RPG Sim
2009/6/2
RPG Sim