Hi there! I’m using a public FMODUnity.EventReference to hold reference to a sound, but I’m leaving the path empty since I dont have the sound yet.
I’m trying to not call it if it’s null by calling EventReference.IsNull but, it returns not-null. The path is empty on my Unity Editor, but Debug.Log returns a GUID for this EventReference, so it’s not-null.
This is just checking if the Event Path is left empty in the Unity Editor
public FMODUnity.EventReference reference;
// Start is called before the first frame update
void Start()
{
if (reference.Path.Length > 0)
{
Debug.Log("Path");
}
else
Debug.Log("No path");
}
The script will just need a reference to the Event Reference.