Unity save gameobject list? (Save System)
For example; GameObject has a script. Script props -> name and age. I have 10 GameObject. I need to save those GameObjects. How can i make this? Thanks.
Comment
Answer by XeniaPhe · Feb 28, 2021 at 02:18 PM
you can create an empty gameobject and give it a script which will hold the data of all your particular gameobjects(say foo):
public foo[] myFoos;
void Start()
{
myFoos = FindObjectsOfType<foo>();
}