diff --git a/otp/avatar/DistributedPlayer.py b/otp/avatar/DistributedPlayer.py index 87156f5f..bf8a5099 100755 --- a/otp/avatar/DistributedPlayer.py +++ b/otp/avatar/DistributedPlayer.py @@ -188,23 +188,6 @@ class DistributedPlayer(DistributedAvatar.DistributedAvatar, PlayerBase.PlayerBa if not quiet: pass - def b_setChat(self, chatString, chatFlags): - if self.cr.wantMagicWords and len(chatString) > 0 and chatString[0] == '~': - messenger.send('magicWord', [chatString]) - else: - if base.config.GetBool('want-chatfilter-hacks', 0): - if base.config.GetBool('want-chatfilter-drop-offending', 0): - if badwordpy.test(chatString): - return - else: - chatString = badwordpy.scrub(chatString) - messenger.send('wakeup') - self.setChatAbsolute(chatString, chatFlags) - self.d_setChat(chatString, chatFlags) - - def d_setChat(self, chatString, chatFlags): - self.sendUpdate('setChat', [chatString, chatFlags, 0]) - def setTalk(self, fromAV, fromAC, avatarName, chat, mods, flags): if not base.cr.verifyMessage(chat): return @@ -235,20 +218,6 @@ class DistributedPlayer(DistributedAvatar.DistributedAvatar, PlayerBase.PlayerBa def scrubTalk(self, chat, mods): return chat - def setChat(self, chatString, chatFlags, DISLid): - self.notify.error('Should call setTalk') - chatString = base.talkAssistant.whiteListFilterMessage(chatString) - if base.localAvatar.isIgnored(self.doId): - return - if base.localAvatar.garbleChat and not self.isUnderstandable(): - chatString = self.chatGarbler.garble(self, chatString) - chatFlags &= ~(CFQuicktalker | CFPageButton | CFQuitButton) - if chatFlags & CFThought: - chatFlags &= ~(CFSpeech | CFTimeout) - else: - chatFlags |= CFSpeech | CFTimeout - self.setChatAbsolute(chatString, chatFlags) - def b_setSC(self, msgIndex): self.setSC(msgIndex) self.d_setSC(msgIndex) diff --git a/otp/avatar/DistributedPlayerAI.py b/otp/avatar/DistributedPlayerAI.py index c797ae03..147240bd 100755 --- a/otp/avatar/DistributedPlayerAI.py +++ b/otp/avatar/DistributedPlayerAI.py @@ -64,16 +64,6 @@ class DistributedPlayerAI(DistributedAvatarAI.DistributedAvatarAI, PlayerBase.Pl def decrementPopulation(self): simbase.air.decrementPopulation() - def b_setChat(self, chatString, chatFlags): - self.setChat(chatString, chatFlags) - self.d_setChat(chatString, chatFlags) - - def d_setChat(self, chatString, chatFlags): - self.sendUpdate('setChat', [chatString, chatFlags]) - - def setChat(self, chatString, chatFlags): - pass - def d_setMaxHp(self, maxHp): DistributedAvatarAI.DistributedAvatarAI.d_setMaxHp(self, maxHp) self.air.writeServerEvent('setMaxHp', self.doId, '%s' % maxHp) diff --git a/otp/chat/ChatAgentUD.py b/otp/chat/ChatAgentUD.py index cc1f700a..f9dd371d 100755 --- a/otp/chat/ChatAgentUD.py +++ b/otp/chat/ChatAgentUD.py @@ -39,7 +39,7 @@ class ChatAgentUD(DistributedObjectGlobalUD): else: cleanMessage, modifications = message, [] self.air.writeServerEvent('chat-said', avId=sender, chatMode=chatMode, msg=message, cleanMsg=cleanMessage) - + # TODO: The above is probably a little too ugly for my taste... Maybe AIR # should be given an API for sending updates for unknown objects? if chatMode != 0: diff --git a/toontown/coghq/DistributedLawOfficeFloor.py b/toontown/coghq/DistributedLawOfficeFloor.py index 2795a941..5823fcbb 100755 --- a/toontown/coghq/DistributedLawOfficeFloor.py +++ b/toontown/coghq/DistributedLawOfficeFloor.py @@ -85,7 +85,7 @@ class DistributedLawOfficeFloor(DistributedLevel.DistributedLevel, LawOfficeBase h = base.localAvatar.getH(self.getZoneNode(self.lastToonZone)) print 'factory pos: %s, h: %s, zone %s' % (repr(pos), h, self.lastToonZone) posStr = 'X: %.3f' % pos[0] + '\nY: %.3f' % pos[1] + '\nZ: %.3f' % pos[2] + '\nH: %.3f' % h + '\nZone: %s' % str(self.lastToonZone) - base.localAvatar.setChat(posStr, CFThought, 0) + base.localAvatar.setChatAbsolute(posStr, CFThought) self.accept('f2', printPos) base.localAvatar.setCameraCollisionsCanMove(1)