Emitters' EventReference.Path not included in build?


I see that the EventReference.Path is excluded from builds (#if UNITY_EDITOR), only GUID is kept and not really easy to use (that I know of).
How should I proceed to get that event’s name then ? Am I supposed to use the GUID somewhere to get that path ?

Thanks for the help :slight_smile:

You should be able to get the event’s name by grabbing the GUID from your EventReference, and passing it to Studio::System::lookupPath to get the corresponding path.

Hope that helps!

That was a good starting point. Ended up finding this post : Is there a way to lookup Path by GUID?

static public string getPath(FMOD.GUID guid)
    string path = string.Empty;

    //FMOD.Studio.System sys;
    //FMOD.Studio.System.create(out sys);
    //sys.lookupPath(guid, out path);

    RuntimeManager.StudioSystem.lookupPath(guid, out path);

    return path;

Thanks :slight_smile:

1 Like