示例#1
0
    def announceGenerate(self):
        DistributedAvatarAI.announceGenerate(self)
        self.clearTrack()
        self.track = Sequence(Wait(0.1), Func(self.spawn))
        self.track.start()

        # Let's set the combo data task name and start the task.
        self.comboDataTaskName = self.uniqueName('clearComboData')
        taskMgr.add(self.clearComboData, self.comboDataTaskName)
    def announceGenerate(self):
        DistributedAvatarAI.announceGenerate(self)
        DistributedSmoothNodeAI.announceGenerate(self)
        if self.parentId != self.getDefaultShard():
            self.b_setDefaultShard(self.parentId)

        if self.__class__.__name__ == "DistributedToonAI":
            # TEMPORARY: Any new gags that we make have to be given to toons automatically.
            newGags = GagGlobals.gagIds.keys()
            currentGags = self.backpack.gags
            needsToUpdate = False
            for newGag in newGags:
                if not newGag in currentGags.keys():
                    print 'This player is missing {0}'.format(GagGlobals.getGagByID(newGag))
                    self.backpack.addGag(newGag)
                    if not needsToUpdate:
                        needsToUpdate = True
            if needsToUpdate:
                self.backpack.updateNetAmmo()
示例#3
0
 def announceGenerate(self):
     DistributedAvatarAI.announceGenerate(self)
     DistributedSmoothNodeAI.announceGenerate(self)
示例#4
0
 def announceGenerate(self):
     DistributedAvatarAI.announceGenerate(self)
     self.clearTrack()
     self.track = Sequence(Wait(0.1), Func(self.spawn))
     self.track.start()
示例#5
0
 def announceGenerate(self):
     DistributedAvatarAI.announceGenerate(self)
     if self.track:
         self.track.pause()
         self.track = None
     Sequence(Wait(0.1), Func(self.spawn)).start()
示例#6
0
 def announceGenerate(self):
     DistributedAvatarAI.announceGenerate(self)
     data = CHAR_DATA[self.charId]
     self.talkEnabled = data[4]
     self.fsm.request('neutral', [True])