Quantcast
Channel: Latest Questions by Brian-Kehrer
Viewing all articles
Browse latest Browse all 18

Storing data about an asset only in the editor

$
0
0

I'm building a library of scriptable objects, each of which depends on some mesh data.

I'd like the ScriptableObjects I'm containing to maintain a reference to their source mesh (for ease of updating in the editor), while not depending on that reference at runtime, to save on memory.

It appears custom editors cannot persist data - is there a bucket for preference data related to an object - namely, Unity must do something similar with imported assets.

My guess, from the way it looks in the editor is that it's sort of like a Proxy pattern, with root level scriptableObjects having a reference to the actual game object (for example a ImportedMesh asset with reference to the resulting Mesh asset, or the fonts in which case the texture is the resulting data.

This is of course quite doable to implement, however, I'm wondering if there is an architecturally better way to implement this?
What is the best way to store data about an object that does not get included at build time?


Viewing all articles
Browse latest Browse all 18

Trending Articles