Question by
pistoleta · May 07, 2019 at 04:24 PM ·
scriptableobjectscriptable object
I'm using 1 Scriptable Object to save my collection of events.
Hi. I created 1 Scriptable Object where I save a list of hundreds of events I will define... such as.. when Events are made of primitive values and have the structure:
variableX
logic operator valueY
triggeredAction
Something similar to this:
public class EventSO : SerializedScriptableObject
{
[SerializeField]
public List<MyEvent> myEvents;
}
[Serializable]
public class MyEvent
{
public string varCode;
public string logicOp; // > < ==
public float value;
public string action;
}
I read is not good to save lots of data into the same Scriptable Object but I also find quite absurd to save 1 event into 1 scriptable object.
Do you think this is a bad use of scriptable objects? Any advice or suggestion would be appreciated. Thanks a lot. pistoleta
Comment