def __init__(self, parentFSM, doneEvent, dnaStore, hoodId): Hood.__init__(self, parentFSM, doneEvent, dnaStore, hoodId) self.loader = None self.fsm = ClassicFSM.ClassicFSM('Hood', [ State.State('start', self.enterStart, self.exitStart, ['safeZoneLoader']), State.State('safeZoneLoader', self.enterSafeZoneLoader, self.exitSafeZoneLoader, ['quietZone']), State.State('quietZone', self.enterQuietZone, self.exitQuietZone, ['safeZoneLoader']), State.State('final', self.enterFinal, self.exitFinal, []) ], 'start', 'final') self.fsm.enterInitialState() self.id = MyEstate self.safeZoneLoaderClass = EstateLoader self.storageDNAFile = 'phase_5.5/dna/storage_estate.pdna' self.holidayStorageDNADict = { WINTER_DECORATIONS: ['phase_5.5/dna/winter_storage_estate.pdna'], WACKY_WINTER_DECORATIONS: ['phase_5.5/dna/winter_storage_estate.pdna'], HALLOWEEN_PROPS: ['phase_5.5/dna/halloween_props_storage_estate.pdna'], SPOOKY_PROPS: ['phase_5.5/dna/halloween_props_storage_estate.pdna'] } self.skyFile = 'phase_3.5/models/props/TT_sky' self.spookySkyFile = 'phase_3.5/models/props/BR_sky' self.popupInfo = None
def __init__(self, parentFSM, doneEvent, dnaStore, hoodId): Hood.__init__(self, parentFSM, doneEvent, dnaStore, hoodId) self.suitInteriorDoneEvent = 'suitInteriorDone' self.minigameDoneEvent = 'minigameDone' self.whiteFogColor = Vec4(0.8, 0.8, 0.8, 1) self.fsm = ClassicFSM.ClassicFSM('Hood', [State.State('start', self.enterStart, self.exitStart, ['townLoader', 'safeZoneLoader']), State.State('townLoader', self.enterTownLoader, self.exitTownLoader, ['quietZone', 'safeZoneLoader', 'suitInterior', 'cogdoInterior']), State.State('safeZoneLoader', self.enterSafeZoneLoader, self.exitSafeZoneLoader, ['quietZone', 'suitInterior', 'cogdoInterior', 'townLoader', 'minigame']), State.State('purchase', self.enterPurchase, self.exitPurchase, ['quietZone', 'minigame', 'safeZoneLoader']), State.State('suitInterior', self.enterSuitInterior, self.exitSuitInterior, ['quietZone', 'townLoader', 'safeZoneLoader']), State.State('cogdoInterior', self.enterCogdoInterior, self.exitCogdoInterior, ['quietZone', 'townLoader', 'safeZoneLoader']), State.State('minigame', self.enterMinigame, self.exitMinigame, ['purchase']), State.State('quietZone', self.enterQuietZone, self.exitQuietZone, ['safeZoneLoader', 'townLoader', 'suitInterior', 'cogdoInterior', 'minigame']), State.State('final', self.enterFinal, self.exitFinal, [])], 'start', 'final') self.fsm.enterInitialState() self.underwaterColor = None # Until we cleanup Hood, we will need to define some variables self.id = self.ID self.storageDNAFile = self.STORAGE_DNA self.holidayStorageDNADict = self.HOLIDAY_DNA self.skyFile = self.SKY_FILE self.spookySkyFile = self.SPOOKY_SKY_FILE self.titleColor = self.TITLE_COLOR
def __init__(self, parentFSM, doneEvent, dnaStore, hoodId): Hood.__init__(self, parentFSM, doneEvent, dnaStore, hoodId) self.fsm = ClassicFSM.ClassicFSM( 'Hood', [State.State('start', self.enterStart, self.exitStart, ['cogHQLoader']), State.State('cogHQLoader', self.enterCogHQLoader, self.exitCogHQLoader, ['quietZone']), State.State('quietZone', self.enterQuietZone, self.exitQuietZone, ['cogHQLoader']), State.State('final', self.enterFinal, self.exitFinal, []) ], 'start', 'final') self.fsm.enterInitialState() # Until Hood is cleaned up, we will need to define some variables: self.id = self.ID self.storageDNAFile = None self.skyFile = self.SKY_FILE self.titleColor = self.TITLE_COLOR
def __init__(self, parentFSM, doneEvent, dnaStore, hoodId): Hood.__init__(self, parentFSM, doneEvent, dnaStore, hoodId) self.suitInteriorDoneEvent = 'suitInteriorDone' self.minigameDoneEvent = 'minigameDone' self.whiteFogColor = Vec4(0.8, 0.8, 0.8, 1) self.fsm = ClassicFSM.ClassicFSM('Hood', [ State.State('start', self.enterStart, self.exitStart, ['townLoader', 'safeZoneLoader']), State.State('townLoader', self.enterTownLoader, self.exitTownLoader, [ 'quietZone', 'safeZoneLoader', 'suitInterior', 'cogdoInterior' ]), State.State('safeZoneLoader', self.enterSafeZoneLoader, self.exitSafeZoneLoader, [ 'quietZone', 'suitInterior', 'cogdoInterior', 'townLoader', 'minigame' ]), State.State('purchase', self.enterPurchase, self.exitPurchase, ['quietZone', 'minigame', 'safeZoneLoader']), State.State('suitInterior', self.enterSuitInterior, self.exitSuitInterior, ['quietZone', 'townLoader', 'safeZoneLoader']), State.State('cogdoInterior', self.enterCogdoInterior, self.exitCogdoInterior, ['quietZone', 'townLoader', 'safeZoneLoader']), State.State('minigame', self.enterMinigame, self.exitMinigame, ['purchase']), State.State('quietZone', self.enterQuietZone, self.exitQuietZone, [ 'safeZoneLoader', 'townLoader', 'suitInterior', 'cogdoInterior', 'minigame' ]), State.State('final', self.enterFinal, self.exitFinal, []) ], 'start', 'final') self.fsm.enterInitialState() # Load content pack ambience settings: ambience = contentPacksMgr.getAmbience('general') color = ambience.get('underwater-color') if color is not None: try: self.underwaterColor = Vec4(color['r'], color['g'], color['b'], color['a']) except Exception as e: raise ContentPackError(e) else: self.underwaterColor = None # Until we cleanup Hood, we will need to define some variables self.id = self.ID self.storageDNAFile = self.STORAGE_DNA self.holidayStorageDNADict = self.HOLIDAY_DNA self.skyFile = self.SKY_FILE self.spookySkyFile = self.SPOOKY_SKY_FILE self.titleColor = self.TITLE_COLOR
def __init__(self, parentFSM, doneEvent, dnaStore, hoodId): Hood.__init__(self, parentFSM, doneEvent, dnaStore, hoodId) self.fsm = ClassicFSM.ClassicFSM('Hood', [State.State('start', self.enterStart, self.exitStart, ['cogHQLoader']), State.State('cogHQLoader', self.enterCogHQLoader, self.exitCogHQLoader, ['quietZone']), State.State('quietZone', self.enterQuietZone, self.exitQuietZone, ['cogHQLoader']), State.State('final', self.enterFinal, self.exitFinal, [])], 'start', 'final') self.fsm.enterInitialState() self.id = self.ID self.storageDNAFile = None self.skyFile = self.SKY_FILE self.titleColor = self.TITLE_COLOR
def __init__(self, parentFSM, doneEvent, dnaStore, hoodId): Hood.__init__(self, parentFSM, doneEvent, dnaStore, hoodId) self.fsm = ClassicFSM.ClassicFSM('Hood', [State.State('start', self.enterStart, self.exitStart, ['safeZoneLoader']), State.State('safeZoneLoader', self.enterSafeZoneLoader, self.exitSafeZoneLoader, ['quietZone']), State.State('quietZone', self.enterQuietZone, self.exitQuietZone, ['safeZoneLoader']), State.State('final', self.enterFinal, self.exitFinal, [])], 'start', 'final') self.fsm.enterInitialState() self.id = MyEstate self.safeZoneLoaderClass = EstateLoader self.storageDNAFile = 'phase_5.5/dna/storage_estate.pdna' self.holidayStorageDNADict = { CHRISTMAS: ['phase_5.5/dna/winter_storage_estate.pdna'], HALLOWEEN: ['phase_5.5/dna/halloween_props_storage_estate.pdna']} self.skyFile = 'phase_3.5/models/props/TT_sky' self.spookySkyFile = 'phase_3.5/models/props/BR_sky' self.popupInfo = None
def __init__(self, parentFSM, doneEvent, dnaStore, hoodId): Hood.__init__(self, parentFSM, doneEvent, dnaStore, hoodId) self.suitInteriorDoneEvent = 'suitInteriorDone' self.minigameDoneEvent = 'minigameDone' self.whiteFogColor = Vec4(0.8, 0.8, 0.8, 1) self.fsm = ClassicFSM.ClassicFSM('Hood', [State.State('start', self.enterStart, self.exitStart, ['townLoader', 'safeZoneLoader']), State.State('townLoader', self.enterTownLoader, self.exitTownLoader, ['quietZone', 'safeZoneLoader', 'suitInterior', 'cogdoInterior']), State.State('safeZoneLoader', self.enterSafeZoneLoader, self.exitSafeZoneLoader, ['quietZone', 'suitInterior', 'cogdoInterior', 'townLoader', 'minigame']), State.State('purchase', self.enterPurchase, self.exitPurchase, ['quietZone', 'minigame', 'safeZoneLoader']), State.State('suitInterior', self.enterSuitInterior, self.exitSuitInterior, ['quietZone', 'townLoader', 'safeZoneLoader']), State.State('cogdoInterior', self.enterCogdoInterior, self.exitCogdoInterior, ['quietZone', 'townLoader', 'safeZoneLoader']), State.State('minigame', self.enterMinigame, self.exitMinigame, ['purchase']), State.State('quietZone', self.enterQuietZone, self.exitQuietZone, ['safeZoneLoader', 'townLoader', 'suitInterior', 'cogdoInterior', 'minigame']), State.State('final', self.enterFinal, self.exitFinal, [])], 'start', 'final') self.fsm.enterInitialState() # Load content pack ambience settings: ambience = contentPacksMgr.getAmbience('general') color = ambience.get('underwater-color') if color is not None: try: self.underwaterColor = Vec4(color['r'], color['g'], color['b'], color['a']) except Exception, e: raise ContentPackError(e)
def __init__(self, parentFSM, doneEvent, dnaStore, hoodId): Hood.__init__(self, parentFSM, doneEvent, dnaStore, hoodId) self.suitInteriorDoneEvent = 'suitInteriorDone' self.minigameDoneEvent = 'minigameDone' self.whiteFogColor = Vec4(0.8, 0.8, 0.8, 1) self.fsm = ClassicFSM.ClassicFSM('Hood', [State.State('start', self.enterStart, self.exitStart, ['townLoader', 'safeZoneLoader']), State.State('townLoader', self.enterTownLoader, self.exitTownLoader, ['quietZone', 'safeZoneLoader', 'suitInterior', 'cogdoInterior']), State.State('safeZoneLoader', self.enterSafeZoneLoader, self.exitSafeZoneLoader, ['quietZone', 'suitInterior', 'cogdoInterior', 'townLoader', 'minigame']), State.State('purchase', self.enterPurchase, self.exitPurchase, ['quietZone', 'minigame', 'safeZoneLoader']), State.State('suitInterior', self.enterSuitInterior, self.exitSuitInterior, ['quietZone', 'townLoader', 'safeZoneLoader']), State.State('cogdoInterior', self.enterCogdoInterior, self.exitCogdoInterior, ['quietZone', 'townLoader', 'safeZoneLoader']), State.State('minigame', self.enterMinigame, self.exitMinigame, ['purchase']), State.State('quietZone', self.enterQuietZone, self.exitQuietZone, ['safeZoneLoader', 'townLoader', 'suitInterior', 'cogdoInterior', 'minigame']), State.State('final', self.enterFinal, self.exitFinal, [])], 'start', 'final') self.fsm.enterInitialState() # Until we cleanup Hood, we will need to define some variables self.id = self.ID self.storageDNAFile = self.STORAGE_DNA self.holidayStorageDNADict = self.HOLIDAY_DNA self.skyFile = self.SKY_FILE self.spookySkyFile = self.SPOOKY_SKY_FILE self.titleColor = self.TITLE_COLOR