7/1/2023 0 Comments Pokemon unity games![]() However, scriptable objects have their limitations when it comes to editor support. When the standard controls for public fields are insufficient for your purpose, you can use Editor Scripting to enhance the inspector of these assets to better fulfill your game designers needs. So you can, for example, have another ScriptableObject type for the various attacks your creatures can perform and then assign attacks to creature types via drag&drop. You can also have ScriptableObjects referencing other ScriptableObjects. You can then assign these assets to inspector properties of MonoBehaviour's and thus assign them to prefabs or objects within your scene. This enables you to create "CreatureType" assets in the Unity editor which you can then manage in the Unity project outline like any other Unity asset. So you could create a class CreatureType : ScriptableObject. A scriptable object is a game-specific asset type. ![]() Solution within Unity: Scriptable ObjectsĪ solution completely within Unity would be to work with scriptable objects. But when the data is less than a couple hundred MB, I would look for a solution which loads all the data when the game starts and then allow the game to access it directly. The only exception would be if I had so much data that it won't all fit into RAM. I would generally not use a SQL database (not even SQLite) for handling static data in a singleplayer game.
0 Comments
Leave a Reply. |