當前位置: 首頁>>代碼示例>>Python>>正文


Python battle.BattleExperienceAI類代碼示例

本文整理匯總了Python中toontown.battle.BattleExperienceAI的典型用法代碼示例。如果您正苦於以下問題:Python BattleExperienceAI類的具體用法?Python BattleExperienceAI怎麽用?Python BattleExperienceAI使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


在下文中一共展示了BattleExperienceAI類的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。

示例1: __doneVictory

 def __doneVictory(self, avIds):
     self.d_setBattleExperience()
     self.b_setState('Reward')
     BattleExperienceAI.assignRewards(self.involvedToons, self.toonSkillPtsGained, self.suitsKilled, ToontownGlobals.dept2cogHQ(self.dept), self.helpfulToons)
     for toonId in self.involvedToons:
         toon = self.air.doId2do.get(toonId)
         if toon:
             self.givePinkSlipReward(toon)
             toon.b_promote(self.deptIndex)
開發者ID:AdrianF98,項目名稱:Toontown-Rewritten,代碼行數:9,代碼來源:DistributedBossbotBossAI.py

示例2: __doneVictory

 def __doneVictory(self, avIds):
     self.d_setBattleExperience()
     self.b_setState('Reward')
     BattleExperienceAI.assignRewards(self.involvedToons, self.toonSkillPtsGained, self.suitsKilled, ToontownGlobals.dept2cogHQ(self.dept), self.helpfulToons)
     for toonId in self.involvedToons:
         toon = self.air.doId2do.get(toonId)
         if toon:
             for i in xrange(5):
                 toon.addResistanceMessage(self.rewardId)
             toon.b_promote(self.deptIndex)
開發者ID:ToontownInfiniteReturns,項目名稱:Source,代碼行數:10,代碼來源:DistributedCashbotBossAI.py

示例3: __doneVictory

 def __doneVictory(self, avIds):
     self.d_setBattleExperience()
     self.b_setState('Reward')
     BattleExperienceAI.assignRewards(self.involvedToons, self.toonSkillPtsGained, self.suitsKilled, ToontownGlobals.dept2cogHQ(self.dept), self.helpfulToons)
     for toonId in self.involvedToons:
         toon = self.air.doId2do.get(toonId)
         if toon:
             if not toon.attemptAddNPCFriend(self.cagedToonNpcId, numCalls=1):
                 self.notify.info('%s.unable to add NPCFriend %s to %s.' % (self.doId, self.cagedToonNpcId, toonId))
             toon.b_promote(self.deptIndex)
開發者ID:nate97,項目名稱:src,代碼行數:10,代碼來源:DistributedSellbotBossAI.py

示例4: __doneVictory

 def __doneVictory(self, avIds):
     self.d_setBattleExperience()
     self.b_setState('Reward')
     BattleExperienceAI.assignRewards(self.involvedToons, self.toonSkillPtsGained, self.suitsKilled, ToontownGlobals.dept2cogHQ(self.dept), self.helpfulToons)
     preferredDept = random.randrange(len(SuitDNA.suitDepts))
     typeWeights = ['single'] * 70 + ['building'] * 27 + ['invasion'] * 3
     preferredSummonType = random.choice(typeWeights)
     for toonId in self.involvedToons:
         toon = self.air.doId2do.get(toonId)
         if toon:
             self.giveCogSummonReward(toon, preferredDept, preferredSummonType)
             toon.b_promote(self.deptIndex)
開發者ID:CoolFangs,項目名稱:src,代碼行數:12,代碼來源:DistributedLawbotBossAI.py

示例5: getBattleExperience

 def getBattleExperience(self):
     result = BattleExperienceAI.getBattleExperience(
         8,
         self.involvedToons,
         self.toonExp,
         self.toonSkillPtsGained,
         self.toonOrigQuests,
         self.toonItems,
         self.toonOrigMerits,
         self.toonMerits,
         self.toonParts,
         self.suitsKilled,
         self.helpfulToons)
     return result
開發者ID:Toonerz,項目名稱:Toontown-World-Online-Leak,代碼行數:14,代碼來源:DistributedBossCogAI.py


注:本文中的toontown.battle.BattleExperienceAI類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。