diff --git a/toontown/battle/BattleSounds.py b/toontown/battle/BattleSounds.py index 2a61838..2acff8e 100644 --- a/toontown/battle/BattleSounds.py +++ b/toontown/battle/BattleSounds.py @@ -1,7 +1,5 @@ from pandac.PandaModules import * from direct.directnotify import DirectNotifyGlobal -from direct.showbase import AppRunnerGlobal -import os class BattleSounds: notify = DirectNotifyGlobal.directNotify.newCategory('BattleSounds') @@ -19,20 +17,12 @@ class BattleSounds: def setupSearchPath(self): self.sfxSearchPath = DSearchPath() - if AppRunnerGlobal.appRunner: - self.sfxSearchPath.appendDirectory(Filename.expandFrom('$TT_3_ROOT/phase_3/audio/sfx')) - self.sfxSearchPath.appendDirectory(Filename.expandFrom('$TT_3_5_ROOT/phase_3.5/audio/sfx')) - self.sfxSearchPath.appendDirectory(Filename.expandFrom('$TT_4_ROOT/phase_4/audio/sfx')) - self.sfxSearchPath.appendDirectory(Filename.expandFrom('$TT_5_ROOT/phase_5/audio/sfx')) - else: - self.sfxSearchPath.appendDirectory(Filename('phase_3/audio/sfx')) - self.sfxSearchPath.appendDirectory(Filename('phase_3.5/audio/sfx')) - self.sfxSearchPath.appendDirectory(Filename('phase_4/audio/sfx')) - self.sfxSearchPath.appendDirectory(Filename('phase_5/audio/sfx')) - self.sfxSearchPath.appendDirectory(Filename.fromOsSpecific(os.path.expandvars('$TTMODELS/built/phase_3/audio/sfx'))) - self.sfxSearchPath.appendDirectory(Filename.fromOsSpecific(os.path.expandvars('$TTMODELS/built/phase_3.5/audio/sfx'))) - self.sfxSearchPath.appendDirectory(Filename.fromOsSpecific(os.path.expandvars('$TTMODELS/built/phase_4/audio/sfx'))) - self.sfxSearchPath.appendDirectory(Filename.fromOsSpecific(os.path.expandvars('$TTMODELS/built/phase_5/audio/sfx'))) + if __debug__: + # In the dev environment, it will always be here: + self.sfxSearchPath.appendDirectory(Filename('resources/phase_3/audio/sfx')) + self.sfxSearchPath.appendDirectory(Filename('resources/phase_3.5/audio/sfx')) + self.sfxSearchPath.appendDirectory(Filename('resources/phase_4/audio/sfx')) + self.sfxSearchPath.appendDirectory(Filename('resources/phase_5/audio/sfx')) def clear(self): if self.isValid: