I'm trying to do a Potencial Visibility Set system and I have some problems about the runtime. In the editor I have a button in a editor class to calculate which transforms are potencialy visible. This metod is very expensive and I save to disk this informations in a XML file.
The XML is like this:
Every number is a transform ID that I get it with metod GetInstanceID.
I want to transform this number to a transform again in the start metod of the camera but the only metod that i know is EditorUtility.InstanceIDToObject but it's for the editor only.
Instance IDs are only valid within the same session. In stead I'd suggest saving the path of the GameObject.
Edit: Since you're working with GameObjects with non-unique names, you could alternatively set up a custom asset to store serialized references to your GameObjects.
Custom asset handling: