So I’m creating a soldier customization to my game. We got two prefabs. A helmet prefab and soldier prefab. After player selected which helmet he wants the helmet prefab is instantiated into already existing soldier skeleton(so the animation looks okey with the helmet on). Then player mostlikely will close the customization menu and with that soldier connected with helmet. My question is: how can I save soldier and helmet as one prefab on runtime so it would be instantiated later in the game? I tried saving it into List but after deleting soldier (that already has helmet in it) it also disapears from the List.
I’m propably missing something very crucial here so I ask you for help. Thanks!
If the helmets are in a list or array, save the index number selected as an integer variable to retrieve later on an object with DontDestroyOnLoad()
or a script with [RuntimeInitializeOnLoadMethod]
.