diff --git a/otp/otpbase/OTPLocalizerEnglish.py b/otp/otpbase/OTPLocalizerEnglish.py index 2dd8a901..28851dcf 100644 --- a/otp/otpbase/OTPLocalizerEnglish.py +++ b/otp/otpbase/OTPLocalizerEnglish.py @@ -199,7 +199,6 @@ SCMenuBattleStrategy = 'STRATEGY' SCMenuBoardingGroup = 'BOARDING' SCMenuParties = 'PARTIES' SCMenuAprilToons = "APRIL TOONS'" -SCMenuSingingGroup = 'SINGING' SCMenuCarol = 'CAROLING' SCMenuSillyHoliday = 'SILLY METER' SCMenuVictoryParties = 'VICTORY PARTIES' @@ -2391,7 +2390,6 @@ SellbotNerfMenuSections = [-1, 'GROUPING', 'SELLBOT TOWERS/VP'] JellybeanJamMenuSections = ['GET JELLYBEANS', 'SPEND JELLYBEANS'] WinterMenuSections = ['CAROLING', -1] HalloweenMenuSections = [-1] -SingingMenuSections = [-1] WhiteListMenu = [-1, 'WHITELIST'] SellbotInvasionMenuSections = [-1] SellbotFieldOfficeMenuSections = [-1, 'STRATEGY'] diff --git a/toontown/building/DistributedBoardingParty.py b/toontown/building/DistributedBoardingParty.py index 8a42a93b..d10536a2 100644 --- a/toontown/building/DistributedBoardingParty.py +++ b/toontown/building/DistributedBoardingParty.py @@ -41,8 +41,6 @@ class DistributedBoardingParty(DistributedObject.DistributedObject, BoardingPart canonicalZoneId = ZoneUtil.getCanonicalZoneId(self.zoneId) self.notify.debug('canonicalZoneId = %s' % canonicalZoneId) localAvatar.chatMgr.chatInputSpeedChat.addBoardingGroupMenu(canonicalZoneId) - if base.config.GetBool('want-singing', 0): - localAvatar.chatMgr.chatInputSpeedChat.addSingingGroupMenu() def delete(self): DistributedObject.DistributedObject.delete(self) diff --git a/toontown/chat/TTChatInputSpeedChat.py b/toontown/chat/TTChatInputSpeedChat.py index cefeda09..c51f49ca 100644 --- a/toontown/chat/TTChatInputSpeedChat.py +++ b/toontown/chat/TTChatInputSpeedChat.py @@ -5,7 +5,6 @@ from toontown.speedchat.TTSpeedChatTypes import * from otp.speedchat.SpeedChat import SpeedChat from otp.speedchat import SpeedChatGlobals from toontown.speedchat import TTSpeedChatGlobals -from toontown.speedchat import TTSCSingingTerminal from toontown.speedchat import TTSCIndexedTerminal from direct.showbase import DirectObject from direct.fsm import ClassicFSM, State @@ -356,7 +355,6 @@ class TTChatInputSpeedChat(DirectObject.DirectObject): self.ceoMenu = None self.golfMenu = None self.boardingGroupMenu = None - self.singingGroupMenu = None self.aprilToonsMenu = None self.victoryPartiesMenu = None self.sillyPhaseOneMenu = None @@ -383,7 +381,6 @@ class TTChatInputSpeedChat(DirectObject.DirectObject): listenForSCEvent(SpeedChatGlobals.SCEmoteNoAccessEvent, self.handleEmoteNoAccess) listenForSCEvent(TTSpeedChatGlobals.TTSCToontaskMsgEvent, self.handleToontaskMsg) listenForSCEvent(TTSpeedChatGlobals.TTSCResistanceMsgEvent, self.handleResistanceMsg) - listenForSCEvent(TTSCSingingTerminal.TTSCSingingMsgEvent, self.handleSingingMsg) listenForSCEvent('SpeedChatStyleChange', self.handleSpeedChatStyleChange) listenForSCEvent(TTSCIndexedTerminal.TTSCIndexedMsgEvent, self.handleStaticTextMsg) self.fsm = ClassicFSM.ClassicFSM('SpeedChat', [State.State('off', self.enterOff, self.exitOff, ['active']), State.State('active', self.enterActive, self.exitActive, ['off'])], 'off', 'off') @@ -469,12 +466,6 @@ class TTChatInputSpeedChat(DirectObject.DirectObject): else: self.chatMgr.sendSCWhisperMessage(textId, self.whisperAvatarId) - def handleSingingMsg(self, textId): - if self.whisperAvatarId is None: - self.chatMgr.sendSCSingingChatMessage(textId) - else: - self.chatMgr.sendSCSingingWhisperMessage(textId) - def handleCustomMsg(self, textId): if self.whisperAvatarId is None: self.chatMgr.sendSCCustomChatMessage(textId) @@ -709,21 +700,6 @@ class TTChatInputSpeedChat(DirectObject.DirectObject): self.boardingGroupMenu = None return - def addSingingGroupMenu(self): - if self.singingGroupMenu == None: - menu = TTSCSingingMenu() - self.singingGroupMenu = SCMenuHolder(OTPLocalizer.SCMenuSingingGroup, menu=menu) - self.speedChat[2:2] = [self.singingGroupMenu] - return - - def removeSingingMenu(self): - if self.singingGroupMenu: - i = self.speedChat.index(self.singingGroupMenu) - del self.speedChat[i] - self.singingGroupMenu.destroy() - self.singingGroupMenu = None - return - def addAprilToonsMenu(self): if self.aprilToonsMenu == None: menu = TTSCAprilToonsMenu() diff --git a/toontown/chat/ToontownChatManager.py b/toontown/chat/ToontownChatManager.py index 59b96917..791343a9 100644 --- a/toontown/chat/ToontownChatManager.py +++ b/toontown/chat/ToontownChatManager.py @@ -70,13 +70,6 @@ class ToontownChatManager(ChatManager.ChatManager): messenger.send('chatUpdateSCResistance', [textId]) self.announceSCChat() - def sendSCSingingChatMessage(self, textId): - messenger.send('chatUpdateSCSinging', [textId]) - self.announceSCChat() - - def sendSCSingingWhisperMessage(self, textId): - pass - def sendSCToontaskChatMessage(self, taskId, toNpcId, toonProgress, msgIndex): messenger.send('chatUpdateSCToontask', [taskId, toNpcId, diff --git a/toontown/speedchat/TTSCSingingMenu.py b/toontown/speedchat/TTSCSingingMenu.py deleted file mode 100644 index ec001d16..00000000 --- a/toontown/speedchat/TTSCSingingMenu.py +++ /dev/null @@ -1,52 +0,0 @@ -from direct.showbase import PythonUtil -from otp.speedchat.SCMenu import SCMenu -from otp.speedchat.SCMenuHolder import SCMenuHolder -from TTSCSingingTerminal import TTSCSingingTerminal -from otp.otpbase import OTPLocalizer -SingingMenuGuide = [(OTPLocalizer.SingingMenuSections[0], [{9000: 25}, - {9001: 26}, - {9002: 27}, - {9003: 28}, - {9004: 29}, - {9005: 30}, - {9006: 31}, - {9007: 32}, - {9008: 33}])] - -class TTSCSingingMenu(SCMenu): - - def __init__(self): - SCMenu.__init__(self) - self.__singingMessagesChanged() - - def destroy(self): - SCMenu.destroy(self) - - def clearMenu(self): - SCMenu.clearMenu(self) - - def __singingMessagesChanged(self): - self.clearMenu() - try: - lt = base.localAvatar - except: - return - - for count in xrange(len(SingingMenuGuide)): - section = SingingMenuGuide[count] - if section[0] == -1: - for phrase in section[1]: - emote = None - if type(phrase) == type({}): - item = phrase.keys()[0] - emote = phrase[item] - phrase = item - if phrase not in OTPLocalizer.SpeedChatStaticText: - print 'warning: tried to link a singing phrase %s which does not seem to exist' % phrase - break - terminal = TTSCSingingTerminal(phrase) - if emote is not None: - terminal.setLinkedEmote(emote) - self.append(terminal) - - return diff --git a/toontown/speedchat/TTSCSingingTerminal.py b/toontown/speedchat/TTSCSingingTerminal.py deleted file mode 100644 index 74184adf..00000000 --- a/toontown/speedchat/TTSCSingingTerminal.py +++ /dev/null @@ -1,24 +0,0 @@ -from otp.speedchat.SCTerminal import SCTerminal -from otp.otpbase.OTPLocalizer import SpeedChatStaticText -TTSCSingingMsgEvent = 'SCSingingMsg' - -def decodeSCStaticTextMsg(textId): - return SpeedChatStaticText.get(textId, None) - - -class TTSCSingingTerminal(SCTerminal): - - def __init__(self, textId): - SCTerminal.__init__(self) - self.textId = textId - self.text = SpeedChatStaticText[self.textId] - - def handleSelect(self): - SCTerminal.handleSelect(self) - messenger.send(self.getEventName(TTSCSingingMsgEvent), [self.textId]) - - def finalize(self): - args = {'rolloverSound': None, - 'clickSound': None} - SCTerminal.finalize(self, args) - return diff --git a/toontown/speedchat/TTSpeedChatTypes.py b/toontown/speedchat/TTSpeedChatTypes.py index f32871b8..1f7fe344 100644 --- a/toontown/speedchat/TTSpeedChatTypes.py +++ b/toontown/speedchat/TTSpeedChatTypes.py @@ -10,7 +10,6 @@ from TTSCResistanceTerminal import TTSCResistanceTerminal from TTSCKartRacingMenu import TTSCKartRacingMenu from TTSCGolfMenu import TTSCGolfMenu from TTSCBoardingMenu import TTSCBoardingMenu -from TTSCSingingMenu import TTSCSingingMenu from TTSCAprilToonsMenu import TTSCAprilToonsMenu from TTSCSillyPhaseOneMenu import TTSCSillyPhaseOneMenu from TTSCSillyPhaseTwoMenu import TTSCSillyPhaseTwoMenu @@ -24,4 +23,4 @@ from TTSCHalloweenMenu import TTSCHalloweenMenu from TTSCWinterMenu import TTSCWinterMenu from TTSCSellbotInvasionMenu import TTSCSellbotInvasionMenu from TTSCSellbotFieldOfficeMenu import TTSCSellbotFieldOfficeMenu -from TTSCIdesOfMarchMenu import TTSCIdesOfMarchMenu +from TTSCIdesOfMarchMenu import TTSCIdesOfMarchMenu \ No newline at end of file diff --git a/toontown/toon/DistributedToon.py b/toontown/toon/DistributedToon.py index ee86b6fc..351d0066 100644 --- a/toontown/toon/DistributedToon.py +++ b/toontown/toon/DistributedToon.py @@ -346,21 +346,9 @@ class DistributedToon(DistributedPlayer.DistributedPlayer, Toon.Toon, Distribute if chatString: self.setChatAbsolute(chatString, CFSpeech | CFQuicktalker | CFTimeout) - def b_setSCSinging(self, msgIndex): - self.setSCSinging(msgIndex) - self.d_setSCSinging(msgIndex) - return None - - def d_setSCSinging(self, msgIndex): - messenger.send('wakeup') - self.sendUpdate('setSCSinging', [msgIndex]) - def sendLogSuspiciousEvent(self, msg): localAvatar.sendUpdate('logSuspiciousEvent', ['%s for %s' % (msg, self.doId)]) - def setSCSinging(self, msgIndex): - self.sendUpdate('logSuspiciousEvent', ['invalid msgIndex in setSCSinging: %s from %s' % (msgIndex, self.doId)]) - def d_reqSCResistance(self, msgIndex): messenger.send('wakeup') nearbyPlayers = self.getNearbyPlayers(ResistanceChat.EFFECT_RADIUS) diff --git a/toontown/toon/DistributedToonAI.py b/toontown/toon/DistributedToonAI.py index c8b0fd69..f6c9a0df 100644 --- a/toontown/toon/DistributedToonAI.py +++ b/toontown/toon/DistributedToonAI.py @@ -3640,13 +3640,6 @@ class DistributedToonAI(DistributedPlayerAI.DistributedPlayerAI, DistributedSmoo if strSearch.search(eventName, 0, 100): self.air.district.recordSuspiciousEventData(len(eventStr)) self.air.writeServerEvent('suspicious', self.doId, eventStr) - if simbase.config.GetBool('want-ban-setSCSinging', True): - if 'invalid msgIndex in setSCSinging:' in eventName: - if senderId == self.doId: - commentStr = 'Toon %s trying to call setSCSinging' % self.doId - simbase.air.banManager.ban(self.doId, self.DISLid, commentStr) - else: - self.notify.warning('logSuspiciousEvent event=%s senderId=%s != self.doId=%s' % (eventName, senderId, self.doId)) if simbase.config.GetBool('want-ban-setAnimState', True): if eventName.startswith('setAnimState: '): if senderId == self.doId: diff --git a/toontown/toon/LocalToon.py b/toontown/toon/LocalToon.py index 627f0841..3e966105 100644 --- a/toontown/toon/LocalToon.py +++ b/toontown/toon/LocalToon.py @@ -483,7 +483,6 @@ class LocalToon(DistributedToon.DistributedToon, LocalAvatar.LocalAvatar): LocalAvatar.LocalAvatar.startChat(self) self.accept('chatUpdateSCToontask', self.b_setSCToontask) self.accept('chatUpdateSCResistance', self.d_reqSCResistance) - self.accept('chatUpdateSCSinging', self.b_setSCSinging) self.accept('whisperUpdateSCToontask', self.whisperSCToontaskTo) else: self.notify.info('NOT calling LocalAvatar.startchat, in tutorial') @@ -492,7 +491,6 @@ class LocalToon(DistributedToon.DistributedToon, LocalAvatar.LocalAvatar): LocalAvatar.LocalAvatar.stopChat(self) self.ignore('chatUpdateSCToontask') self.ignore('chatUpdateSCResistance') - self.ignore('chatUpdateSCSinging') self.ignore('whisperUpdateSCToontask') def tunnelIn(self, tunnelOrigin):