- Home /
Saving Transform Array
Hi guys
I'm trying to save with PlayerPrefs and it worked well, until now. I want to save the inventory (Inv system is from Backeys) The problem is that it uses a Transform array to store the content of my current inventory, and I have no idea how to store it I tried saving the location, rotation but it didn't load it back.
Any ideas?
Okay, sorry:D So here is the Inventory content script: http://pastebin.com/eHgwrEdJ
And here is my save script: http://pastebin.com/8pw1XSJX
You need a way of identifying items, such as a ID value. Without it you will not be able to save arbitrary objects (unless you want to do a ridiculous amount of work.
Or you could try to use Unity Serializer on the asset store that will try to help you with such things and can save Transform references to player prefs.