bye bye
This commit is contained in:
parent
b27fef5b55
commit
f68be54a01
|
|
@ -3,10 +3,7 @@ from toontown.battle import BattlePlace
|
|||
from direct.fsm import ClassicFSM, State
|
||||
from direct.fsm import State
|
||||
from toontown.toonbase import ToontownGlobals
|
||||
from toontown.hood import ZoneUtil
|
||||
from pandac.PandaModules import *
|
||||
from panda3d.otp import *
|
||||
from panda3d.toontown import *
|
||||
from otp.distributed.TelemetryLimiter import RotationLimitToH, TLGatherAllAvs
|
||||
|
||||
class CogHQExterior(BattlePlace.BattlePlace):
|
||||
|
|
@ -76,8 +73,6 @@ class CogHQExterior(BattlePlace.BattlePlace):
|
|||
self.tunnelOriginList = base.cr.hoodMgr.addLinkTunnelHooks(self, self.nodeList, self.zoneId)
|
||||
how = requestStatus['how']
|
||||
self.fsm.request(how, [requestStatus])
|
||||
if __astron__ and self.zoneId != ToontownGlobals.BossbotHQ:
|
||||
self.handleInterests()
|
||||
|
||||
def exit(self):
|
||||
self.fsm.requestFinalState()
|
||||
|
|
@ -138,31 +133,3 @@ class CogHQExterior(BattlePlace.BattlePlace):
|
|||
def exitSquished(self):
|
||||
taskMgr.remove(base.localAvatar.uniqueName('finishSquishTask'))
|
||||
base.localAvatar.laffMeter.stop()
|
||||
|
||||
if __astron__:
|
||||
def handleInterests(self):
|
||||
# First, we need to load the DNA file for this Cog HQ.
|
||||
dnaStore = DNAStorage()
|
||||
dnaFileName = self.genDNAFileName(self.zoneId)
|
||||
loadDNAFileAI(dnaStore, dnaFileName)
|
||||
|
||||
# Next, we need to collect all of the visgroup zone IDs.
|
||||
self.zoneVisDict = {}
|
||||
for i in range(dnaStore.getNumDNAVisGroupsAI()):
|
||||
visGroup = dnaStore.getDNAVisGroupAI(i)
|
||||
groupFullName = visGroup.getName()
|
||||
visZoneId = int(base.cr.hoodMgr.extractGroupName(groupFullName))
|
||||
visZoneId = ZoneUtil.getTrueZoneId(visZoneId, self.zoneId)
|
||||
visibles = []
|
||||
for i in range(visGroup.getNumVisibles()):
|
||||
visibles.append(int(visGroup.getVisibleName(i)))
|
||||
|
||||
visibles.append(ZoneUtil.getBranchZone(visZoneId))
|
||||
self.zoneVisDict[visZoneId] = visibles
|
||||
|
||||
# Finally, we want interest in all visgroups due to this being a Cog HQ.
|
||||
visList = list(self.zoneVisDict.values())[0]
|
||||
if self.zoneId not in visList:
|
||||
visList.append(self.zoneId)
|
||||
|
||||
base.cr.sendSetZoneMsg(self.zoneId, visList)
|
||||
|
|
|
|||
|
|
@ -4,11 +4,8 @@ from direct.fsm import ClassicFSM, State
|
|||
from direct.fsm import State
|
||||
from otp.distributed.TelemetryLimiter import RotationLimitToH, TLGatherAllAvs
|
||||
from toontown.toonbase import ToontownGlobals
|
||||
from toontown.hood import ZoneUtil
|
||||
from toontown.building import Elevator
|
||||
from pandac.PandaModules import *
|
||||
from panda3d.otp import *
|
||||
from panda3d.toontown import *
|
||||
|
||||
class FactoryExterior(BattlePlace.BattlePlace):
|
||||
notify = DirectNotifyGlobal.directNotify.newCategory('FactoryExterior')
|
||||
|
|
@ -74,8 +71,6 @@ class FactoryExterior(BattlePlace.BattlePlace):
|
|||
self.tunnelOriginList = base.cr.hoodMgr.addLinkTunnelHooks(self, self.nodeList, self.zoneId)
|
||||
how = requestStatus['how']
|
||||
self.fsm.request(how, [requestStatus])
|
||||
if __astron__ and self.zoneId != ToontownGlobals.LawbotOfficeExt:
|
||||
self.handleInterests()
|
||||
|
||||
def exit(self):
|
||||
self._telemLimiter.destroy()
|
||||
|
|
@ -157,31 +152,3 @@ class FactoryExterior(BattlePlace.BattlePlace):
|
|||
messenger.send(self.doneEvent)
|
||||
else:
|
||||
self.notify.error('Unknown mode: ' + where + ' in handleElevatorDone')
|
||||
|
||||
if __astron__:
|
||||
def handleInterests(self):
|
||||
# First, we need to load the DNA file for this Cog HQ.
|
||||
dnaStore = DNAStorage()
|
||||
dnaFileName = self.genDNAFileName(self.zoneId)
|
||||
loadDNAFileAI(dnaStore, dnaFileName)
|
||||
|
||||
# Next, we need to collect all of the visgroup zone IDs.
|
||||
self.zoneVisDict = {}
|
||||
for i in range(dnaStore.getNumDNAVisGroupsAI()):
|
||||
visGroup = dnaStore.getDNAVisGroupAI(i)
|
||||
groupFullName = visGroup.getName()
|
||||
visZoneId = int(base.cr.hoodMgr.extractGroupName(groupFullName))
|
||||
visZoneId = ZoneUtil.getTrueZoneId(visZoneId, self.zoneId)
|
||||
visibles = []
|
||||
for i in range(visGroup.getNumVisibles()):
|
||||
visibles.append(int(visGroup.getVisibleName(i)))
|
||||
|
||||
visibles.append(ZoneUtil.getBranchZone(visZoneId))
|
||||
self.zoneVisDict[visZoneId] = visibles
|
||||
|
||||
# Finally, we want interest in all visgroups due to this being a Cog HQ.
|
||||
visList = list(self.zoneVisDict.values())[0]
|
||||
if self.zoneId not in visList:
|
||||
visList.append(self.zoneId)
|
||||
|
||||
base.cr.sendSetZoneMsg(self.zoneId, visList)
|
||||
|
|
|
|||
Loading…
Reference in New Issue