At my first job I was working on an MMO and we had a DatabaseManager class with 10k+ lines of code. Less than the first 200 lines actually used any of the members of that class.
At my first job I was working on an MMO and we had a DatabaseManager class with 10k+ lines of code. Less than the first 200 lines actually used any of the members of that class.
you’d never have player movement in the GameManager class
You want to bet? (Source: I teach game programming on a college level.)
But yeah, your comment about the gear icon is sadly more true than people may realize. Game developers do questionable things. => Engine developers cater to people. => Students argue that if something is supported it can’t be that bad. Sometimes it feels like fighting windmills.
The real naming fail is calling the class “GameManager”, still my number one pet peeve. With a class name as vague as that you would have to add tons of information into the variable name. (Also the class name begs for unorganized code. I mean name one function or variable that you could not justify putting into the “GameManager” class. After all if it’s managing the game it could justifiably perform any process in the game and access any state in it.)
Once you put the first bool into a class with a name like AccessibilitySettings, calling it something like HighContrast is completely sufficient.
You may enjoy having a look at F#. It says that it’s “functional first”, but I think a better description would be “an opinionated version of C#”.
For example it doesn’t have a “const”-keyword. Instead it has a “mutable”-keyword, because everything is const by default.
No, actually C#'s answer should be: “What Java said - hold on, what Python said sounds good too, and C++'s stuff is pretty cool too - let’s go with all of the above.”
C#, or as I like to call it “the Borg of programming languages”.
When I start a free trial I immediately set a reminder in Google calendar. And when I am looking for a specific movie I buy it used online. That way I have all my favorite movies on my NAS and can cancel my subscriptions when there is nothing especially interesting.
Visual studio has been the best IDE for a long time, and OneNote is still the best note taking application.
My hot take: There is no such thing as 0-index. If you start with 1 it’s an index, of you start with 0 it’s an offset.
That doesn’t make it spaghetti code though. In well-written OOP code you shouldn’t care where a function is implemented. The problem is a much too high level of abstraction. If your high level code is so abstract that it is only running tasks and handling messages there’s no way to write it in a way that prevents mistakes because you couldn’t possibly know what the actual implementations do.