def endHoliday(self, holidayId): if holidayId in self.holidayIdList: self.notify.debug('setHolidayId: Ending Holiday %s' % holidayId) self.holidayIdList.remove(holidayId) self.setHoliday(holidayId, 0) SimpleStoreGUI.SimpleStoreGUI.holidayIdList.remove(holidayId) AccessoriesStoreGUI.AccessoriesStoreGUI.holidayIdList.remove(holidayId) JewelryStoreGUI.JewelryStoreGUI.holidayIdList.remove(holidayId) BarberStoreGUI.BarberStoreGUI.holidayIdList.remove(holidayId) TattooStoreGUI.TattooStoreGUI.holidayIdList.remove(holidayId) localAvatar.chatMgr.emoteEntry.updateEmoteList() self.showHolidayMessage(holidayId, 0) if holidayId == HolidayGlobals.HALFOFFCUSTOMIZATION: paidStatus = Freebooter.getPaidStatus(localAvatar.getDoId()) if paidStatus: self.multiplyAllAccessories(2) if holidayId == HolidayGlobals.ALLACCESSWEEKEND: Freebooter.setAllAccess(False) if holidayId == HolidayGlobals.APRILFOOLS: messenger.send('moustacheFlip', [ 0]) messenger.send('HolidayEnded', [ HolidayGlobals.getHolidayName(holidayId)])
def startHoliday(self, holidayId): if holidayId not in self.holidayIdList: self.notify.debug('setHolidayId: Starting Holiday %s' % holidayId) self.holidayIdList.append(holidayId) self.setHoliday(holidayId, 1) SimpleStoreGUI.SimpleStoreGUI.holidayIdList.append(holidayId) AccessoriesStoreGUI.AccessoriesStoreGUI.holidayIdList.append(holidayId) JewelryStoreGUI.JewelryStoreGUI.holidayIdList.append(holidayId) BarberStoreGUI.BarberStoreGUI.holidayIdList.append(holidayId) TattooStoreGUI.TattooStoreGUI.holidayIdList.append(holidayId) localAvatar.chatMgr.emoteEntry.updateEmoteList() self.showHolidayMessage(holidayId, 1) if holidayId == HolidayGlobals.JOLLYROGERCURSE: currentTime = base.cr.timeOfDayManager.getCurrentIngameTime() if currentTime > 18.0 or currentTime < 1.0: self.displayMessage(3) else: self.displayMessage(2) if holidayId == HolidayGlobals.ALLACCESSWEEKEND: Freebooter.setAllAccess(True) localAvatar.guiMgr.stashPrevPanel() if holidayId == HolidayGlobals.APRILFOOLS: messenger.send('moustacheFlip', [ 1]) if holidayId == HolidayGlobals.HALFOFFCUSTOMIZATION: paidStatus = Freebooter.getPaidStatus(localAvatar.getDoId()) if paidStatus: self.divideAllAccessories(2) messenger.send('HolidayStarted', [ HolidayGlobals.getHolidayName(holidayId)])