I always hand a bunch of public static manager classes in my game:
- GameManager (singleton) for reading and writing persistent data and gamestate across scenes
- SceneManager for holding scene data (coins picked up, score, are we in a cutscene)
- UIManager for dealing with HUD stuff
- SfxManager for sound effects
- PfxManager for particle effects
On the gameobject that holds these manager classes, there are also subordinate classes (e.g. HUDManager, a smaller class that managers tasks specific to HUD, and then delegate those tasks into other smaller scripts) in order to avoid monolithic manager classes.
Is this method frowned upon in Unity game development and if so, what are some better solutions than this approach?