Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> It's much more manageable to have a game class object, where inside it, what used to be global could now just a private member that's global to that class.

That's still a global, except now it has lipstick.



If it's private in the class then why are you saying it's global?


"a game class object" is 99.95% likely to contain the whole game. Doesn't matter that it's labeled private, it's basically global to all the code of the ... game.


> 99.95% likely to contain the whole game

That doesn't sound like a wise assumption. It is common to have the actual engine of the game, and even the game itself separate from other architectural components.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: