private void OnApplicationQuit() { #if UNITY_STANDALONE_WIN try { DriveMapper.UnmapDrive(_driveLetter); } catch { } #endif }
private string GetTempPath() { #if UNITY_STANDALONE_WIN try { _driveLetter = DriveMapper.SafeMapDrive(Application.temporaryCachePath); return($"{_driveLetter}:"); } catch (Win32Exception e) { Debug.Log("Mapping failed: " + e.Message); Debug.Log("Using long temp path. Long song names may not convert correctly due to path size."); return(Application.temporaryCachePath); } #else return(Application.temporaryCachePath); #endif }