Add laff meters to all boss battles
This commit is contained in:
parent
2c7ccb4d7d
commit
34d747d58f
4 changed files with 35 additions and 5 deletions
|
@ -396,11 +396,19 @@ class DistributedBossbotBossAI(DistributedBossCogAI.DistributedBossCogAI, FSM.FS
|
|||
self.setupBattleFourObjects()
|
||||
self.battleFourStart = globalClock.getFrameTime()
|
||||
self.waitForNextAttack(5)
|
||||
for toonId in self.involvedToons:
|
||||
toon = simbase.air.doId2do.get(toonId)
|
||||
if toon:
|
||||
toon.b_setHealthDisplay(2)
|
||||
|
||||
def exitBattleFour(self):
|
||||
self.recordCeoInfo()
|
||||
for belt in self.foodBelts:
|
||||
belt.goInactive()
|
||||
for toonId in self.involvedToons:
|
||||
toon = simbase.air.doId2do.get(toonId)
|
||||
if toon:
|
||||
toon.b_setHealthDisplay(0)
|
||||
|
||||
def recordCeoInfo(self):
|
||||
didTheyWin = 0
|
||||
|
|
|
@ -76,6 +76,10 @@ class DistributedCashbotBossAI(DistributedBossCogAI.DistributedBossCogAI, FSM.FS
|
|||
'reserveSuits': reserveSuits}
|
||||
|
||||
def removeToon(self, avId):
|
||||
toon = simbase.air.doId2do.get(avId)
|
||||
if toon:
|
||||
toon.b_setHealthDisplay(0)
|
||||
|
||||
if self.cranes != None:
|
||||
for crane in self.cranes:
|
||||
crane.removeToon(avId)
|
||||
|
@ -434,6 +438,12 @@ class DistributedCashbotBossAI(DistributedBossCogAI.DistributedBossCogAI, FSM.FS
|
|||
taskMgr.remove(taskName)
|
||||
taskMgr.doMethodLater(2, self.__doInitialGoons, taskName)
|
||||
|
||||
for toonId in self.involvedToons:
|
||||
toon = simbase.air.doId2do.get(toonId)
|
||||
if not toon:
|
||||
continue
|
||||
toon.b_setHealthDisplay(2)
|
||||
|
||||
def __doInitialGoons(self, task):
|
||||
self.makeGoon(side='EmergeA')
|
||||
self.makeGoon(side='EmergeB')
|
||||
|
@ -449,6 +459,11 @@ class DistributedCashbotBossAI(DistributedBossCogAI.DistributedBossCogAI, FSM.FS
|
|||
self.stopGoons()
|
||||
self.stopHelmets()
|
||||
self.heldObject = None
|
||||
for toonId in self.involvedToons:
|
||||
toon = simbase.air.doId2do.get(toonId)
|
||||
if not toon:
|
||||
continue
|
||||
toon.b_setHealthDisplay(0)
|
||||
return
|
||||
|
||||
def enterVictory(self):
|
||||
|
|
|
@ -283,6 +283,7 @@ class DistributedLawbotBossAI(DistributedBossCogAI.DistributedBossCogAI, FSM.FSM
|
|||
toon = simbase.air.doId2do.get(avId)
|
||||
if toon:
|
||||
toon.b_setNumPies(0)
|
||||
toon.b_setHealthDisplay(0)
|
||||
DistributedBossCogAI.DistributedBossCogAI.removeToon(self, avId)
|
||||
|
||||
def enterOff(self):
|
||||
|
@ -506,6 +507,7 @@ class DistributedLawbotBossAI(DistributedBossCogAI.DistributedBossCogAI, FSM.FSM
|
|||
toon = simbase.air.doId2do.get(toonId)
|
||||
if toon:
|
||||
toon.__touchedCage = 0
|
||||
toon.b_setHealthDisplay(2)
|
||||
|
||||
for aGavel in self.gavels:
|
||||
aGavel.turnOn()
|
||||
|
@ -624,6 +626,11 @@ class DistributedLawbotBossAI(DistributedBossCogAI.DistributedBossCogAI, FSM.FSM
|
|||
self.__resetLawyers()
|
||||
self.__deleteBattleThreeObjects()
|
||||
|
||||
for toonId in self.involvedToons:
|
||||
toon = self.air.doId2do.get(toonId)
|
||||
if toon:
|
||||
toon.b_setHealthDisplay(0)
|
||||
|
||||
def enterNearVictory(self):
|
||||
self.resetBattles()
|
||||
|
||||
|
|
|
@ -313,6 +313,11 @@ class DistributedSellbotBossAI(DistributedBossCogAI.DistributedBossCogAI, FSM.FS
|
|||
self.stopStrafes()
|
||||
taskName = self.uniqueName('CagedToonSaySomething')
|
||||
taskMgr.remove(taskName)
|
||||
for toonId in self.involvedToons + self.looseToons:
|
||||
toon = self.air.doId2do.get(toonId)
|
||||
if not toon:
|
||||
continue
|
||||
toon.b_setHealthDisplay(0)
|
||||
|
||||
def enterNearVictory(self):
|
||||
self.resetBattles()
|
||||
|
@ -348,11 +353,6 @@ class DistributedSellbotBossAI(DistributedBossCogAI.DistributedBossCogAI, FSM.FS
|
|||
|
||||
def exitVictory(self):
|
||||
self.takeAwayPies()
|
||||
for toonId in self.involvedToons + self.looseToons:
|
||||
toon = self.air.doId2do.get(toonId)
|
||||
if not toon:
|
||||
continue
|
||||
toon.b_setHealthDisplay(0)
|
||||
|
||||
def enterFrolic(self):
|
||||
DistributedBossCogAI.DistributedBossCogAI.enterFrolic(self)
|
||||
|
|
Loading…
Reference in a new issue