Unite Europe 2016 - Overthrowing the MonoBehaviour tyranny in a glorious ScriptableObject revolution
Why Stack Overflow recommends it
Stack Overflow users link it when answering Unity questions about storing game data, replacing singletons, and structuring serialized shared state with ScriptableObjects.
Recommended by 3 people across 3 different months, 2016 to 2018.
What it is
A Unite Europe 2016 talk by Richard Fine of Unity Technologies on using ScriptableObject instead of MonoBehaviour for data and shared state in Unity projects. He works through many practical examples, backed by a public demo project on GitHub.
What people said
Strong rec FreeFly · 2016-12 · Stack Overflow · on “Where to store a real time strategy data?”
I almost forgot! There is THIS [this video] great video about all the things you can do with serialized objects, I'd strongly suggest you to give it a look! Once you have your serialized data, Unity has countless tools to make you build your own editor tools, basic or advanced it's just up to you! Good luck! (and don't forget to mark the right answer as solution!)
Recommends Scott Chamberlain · 2017-01 · Stack Overflow · on “Finding and starting a generic class?”
Singeltons and inhertence don't mix well. I would recommend just dropping the `SingletonMonoBehavior ` and either use a normal `MonoBehavior` on a object that gets loaded in a pre-load scene or even better use a `ScriptableObject` [this video] to represent the shared state.
Recommends Rodrigo Rodrigues · 2018-07 · Stack Overflow · on “Unity data type struggles”
As said by @UnholySheep in the comment, it looks like your code is begging for ScriptableObject [LINK] . They are like MonoBehaviour , but they are not attached to GameObject (so, no transforms and stuff). They can have inspectors and receive some messages like OnDestroy... Inheritance works like a charm with them. You can also make abstract derived classes. Also, serialization is built-in. You define an abstract SerializedObject named Tile , for example, then other child classes ContainerTile , ExtractorTile ... You can create assets of those classes with custom parameters and reference them in components, much like Prefabs, but they are all the same object. Or, you can instantiate them at