So I've dipped my toe in and out of game programming pretty regularly over the past few years and all of the tutorials I've watched and books I've read have all had one thing in common that perplexed me.
Most of the logic in the games I've seen built is completely decentralized and distributed among the various components of the game. There isn't one (or several) central controller(s) that guide how everything interacts with everything else, or that objects and methods in the game defer to to enforce the rules/design.
If an object in a game (a player object for example) impacts a broader game system by say, resetting the level when it reaches 0 health, it doesn't call to some "LevelController" or "LevelController -> GameController" which then resets the level, it just does it itself by directly accessing a built-in game engine directive/method call.
Almost all the actions and interactions from initialization and set up, to combat, collisions, etc. are all resolved in a sort of case-by-case individual bases with all the rules contained solely within various game objects and the only "oversight" being the inherent limits of the game engine itself.
As someone who comes from a pretty traditional top-down Object Oriented development background this whole methodology feels scattershot and piecemeal. It has made it difficult for me to design any kind of holistic architecture for my game projects.
Is it just the case that most intro level projects are like this because they focus on the basic components of a game and how they work and less on more complex, higher level design? Or is it the nature of game design/development in general, perhaps a necessity due to the unique nature of the complexity of games?
Godot
engine does not do that. Taken from here: "changing scene is as simple as replacing a node in the tree by another". Some engines don't work like that. Some engines do. If you find it difficult working this way because you are used to object oriented design, then use an engine that follows that kind of architecture. \$\endgroup\$