oldschool-toontown/toontown/safezone/TTSafeZoneLoader.py

30 lines
1.2 KiB
Python
Raw Normal View History

2019-11-02 17:27:54 -05:00
from pandac.PandaModules import *
from . import SafeZoneLoader
from . import TTPlayground
2019-11-02 17:27:54 -05:00
import random
from toontown.launcher import DownloadForceAcknowledge
class TTSafeZoneLoader(SafeZoneLoader.SafeZoneLoader):
def __init__(self, hood, parentFSM, doneEvent):
SafeZoneLoader.SafeZoneLoader.__init__(self, hood, parentFSM, doneEvent)
self.playgroundClass = TTPlayground.TTPlayground
self.musicFile = 'phase_4/audio/bgm/TC_nbrhood.mid'
self.activityMusicFile = 'phase_3.5/audio/bgm/TC_SZ_activity.mid'
self.dnaFile = 'phase_4/dna/toontown_central_sz.dna'
self.safeZoneStorageDNAFile = 'phase_4/dna/storage_TT_sz.dna'
def load(self):
SafeZoneLoader.SafeZoneLoader.load(self)
self.birdSound = list(map(base.loader.loadSfx, ['phase_4/audio/sfx/SZ_TC_bird1.mp3', 'phase_4/audio/sfx/SZ_TC_bird2.mp3', 'phase_4/audio/sfx/SZ_TC_bird3.mp3']))
2019-11-02 17:27:54 -05:00
def unload(self):
del self.birdSound
SafeZoneLoader.SafeZoneLoader.unload(self)
def enter(self, requestStatus):
SafeZoneLoader.SafeZoneLoader.enter(self, requestStatus)
def exit(self):
SafeZoneLoader.SafeZoneLoader.exit(self)