void ReleaseStudioSystem() { if (studioSystem.isValid()) { studioSystem.release(); studioSystem.clearHandle(); } }
void CheckInitResult(FMOD.RESULT result, string cause) { if (result != FMOD.RESULT.OK) { if (studioSystem.isValid()) { studioSystem.release(); studioSystem.clearHandle(); } throw new SystemNotInitializedException(result, cause); } }
void CheckInitResult(FMOD.RESULT result, string cause) { if (result != FMOD.RESULT.OK) { if (studioSystem != null) { studioSystem.release(); studioSystem = null; } throw new SystemNotInitializedException(result, cause); } }
static void DestroySystem() { if (system.isValid()) { system.release(); system.clearHandle(); } }
static void DestroySystem() { if (system != null) { UnityEngine.Debug.Log("FMOD Studio: Destroying editor system instance"); system.release(); system = null; } }
static void DestroySystem() { if (system.isValid()) { UnityEngine.Debug.Log("FMOD Studio: Destroying editor system instance"); system.release(); system.clearHandle(); } }
private bool disposedValue = false; // To detect redundant calls protected virtual void Dispose(bool disposing) { if (!disposedValue) { Console.WriteLine("FMODSystem: Disposing"); if (disposing) { // TODO: dispose managed state (managed objects). instance = null; } _system.release(); // TODO: free unmanaged resources (unmanaged objects) and override a finalizer below. // TODO: set large fields to null. disposedValue = true; } }