Invest time thinking about the names you give to things.
5 minutes spent finding a meaningful name for a variable can save tens of hours of head-scratching in the future.
The best resource I know for finding good names for variables is chapter 2 of the Clean Code book. You can read it for free on Google Books (the whole book is a good read, but that chapter in particular is great).
kikito wrote:Invest time thinking about the names you give to things.
5 minutes spent finding a meaningful name for a variable can save tens of hours of head-scratching in the future.
The best resource I know for finding good names for variables is chapter 2 of the Clean Code book. You can read it for free on Google Books (the whole book is a good read, but that chapter in particular is great).
Oh yeah, this. Will give the book a read, but I have a notes file devoted to hierachy only, i.e. class/module Spawn places stuff in my game world, therefore it needs to require Actor, Object and Player. If I want to place something, the Area class needs to call Spawn. That sort of thing. Conceptualizing it before coding really helps!