Skip to content

Commit f13d7b3

Browse files
committed
Changed defines.
1 parent b0d28bf commit f13d7b3

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

Runtime/Audio.cs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
// Purpose: Static class for playing audio (clips, sound effects and music).
33
// Created by: DavidFDev
44

5-
//#define HIDE_IN_EDITOR
6-
#define DEBUG_AUDIO
5+
#define HIDE_IN_EDITOR
6+
//#define DEBUG_AUDIO
77

88
using System;
99
using System.Collections;
@@ -165,10 +165,12 @@ public static Playback PlaySfx(string path, Vector3 position = default)
165165
/// <param name="fadeOut">Duration, in seconds, that the old music should take to fade out.</param>
166166
public static void PlayMusic(AudioClip music, float fadeIn = 1f, float fadeOut = 0.75f)
167167
{
168+
#if DEBUG_AUDIO
168169
static string GetAudioClipName(AudioSource source)
169170
{
170171
return source.clip == null ? "none" : source.clip.name;
171172
}
173+
#endif
172174

173175
// Cancel if the new music is the same as the current music
174176
if (music == _musicPlayback.clip)

0 commit comments

Comments
 (0)