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


Python StateData.load方法代碼示例

本文整理匯總了Python中direct.fsm.StateData.StateData.load方法的典型用法代碼示例。如果您正苦於以下問題:Python StateData.load方法的具體用法?Python StateData.load怎麽用?Python StateData.load使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在direct.fsm.StateData.StateData的用法示例。


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

示例1: load

# 需要導入模塊: from direct.fsm.StateData import StateData [as 別名]
# 或者: from direct.fsm.StateData.StateData import load [as 別名]
 def load(self, zoneId):
     StateData.load(self)
     self.zoneId = zoneId
     self.branchZone = ZoneUtil.getBranchZone(zoneId)
     self.canonicalBranchZone = ZoneUtil.getCanonicalBranchZone(zoneId)
     self.music = base.loadMusic(self.musicFile)
     self.interiorMusic = base.loadMusic(self.interiorMusicFile)
開發者ID:coginvasion,項目名稱:src,代碼行數:9,代碼來源:TownLoader.py

示例2: load

# 需要導入模塊: from direct.fsm.StateData import StateData [as 別名]
# 或者: from direct.fsm.StateData.StateData import load [as 別名]
 def load(self):
     StateData.load(self)
     self.book_contents = loader.loadModel('phase_3.5/models/gui/stickerbook_gui.bam')
     self.book_texture = self.book_contents.find('**/big_book')
     self.book_open = loader.loadSfx('phase_3.5/audio/sfx/GUI_stickerbook_open.mp3')
     self.book_close = loader.loadSfx('phase_3.5/audio/sfx/GUI_stickerbook_delete.mp3')
     self.book_turn = loader.loadSfx('phase_3.5/audio/sfx/GUI_stickerbook_turn.mp3')
開發者ID:coginvasion,項目名稱:src,代碼行數:9,代碼來源:ShtickerBook.py

示例3: load

# 需要導入模塊: from direct.fsm.StateData import StateData [as 別名]
# 或者: from direct.fsm.StateData.StateData import load [as 別名]
    def load(self):
        StateData.load(self)
        if self.pgMusicFilename:
            self.music = base.loadMusic(self.pgMusicFilename)
        if self.battleMusicFile:
            self.battleMusic = base.loadMusic(self.battleMusicFile)
        if self.invasionMusicFiles:
            self.invasionMusic = None
        if self.bossBattleMusicFile:
            self.bossBattleMusic = base.loadMusic(self.bossBattleMusicFile)
        if self.interiorMusicFilename:
            self.interiorMusic = base.loadMusic(self.interiorMusicFilename)
        if self.tournamentMusicFiles:
            self.tournamentMusic = None
        self.createSafeZone(self.dnaFile)
        self.parentFSMState.addChild(self.fsm)
        width, height, fs, music, sfx, tex_detail, model_detail, aa, af = SettingsManager().getSettings('settings.json')
        if af == 'on':
            self.notify.info('Anisotropic Filtering is on, applying to textures.')
            for nodepath in self.geom.findAllMatches('*'):
                try:
                    for node in nodepath.findAllMatches('**'):
                        try:
                            node.findTexture('*').setAnisotropicDegree(8)
                        except:
                            pass

                except:
                    continue

        return
開發者ID:coginvasion,項目名稱:src,代碼行數:33,代碼來源:SafeZoneLoader.py

示例4: load

# 需要導入模塊: from direct.fsm.StateData import StateData [as 別名]
# 或者: from direct.fsm.StateData.StateData import load [as 別名]
 def load(self, attackName):
     StateData.load(self)
     className = self.attackName2attackClass[attackName]
     self.currentAttack = className(self, self.suit)
開發者ID:coginvasion,項目名稱:src,代碼行數:6,代碼來源:SuitAttacks.py

示例5: load

# 需要導入模塊: from direct.fsm.StateData import StateData [as 別名]
# 或者: from direct.fsm.StateData.StateData import load [as 別名]
 def load(self):
     StateData.load(self)
開發者ID:coginvasion,項目名稱:src,代碼行數:4,代碼來源:OptionPage.py

示例6: load

# 需要導入模塊: from direct.fsm.StateData import StateData [as 別名]
# 或者: from direct.fsm.StateData.StateData import load [as 別名]
 def load(self):
     StateData.load(self)
     self.walkDoneEvent = 'walkDone'
     self.walkStateData = PublicWalk(self.fsm, self.walkDoneEvent)
     self.walkStateData.load()
開發者ID:coginvasion,項目名稱:src,代碼行數:7,代碼來源:Place.py

示例7: load

# 需要導入模塊: from direct.fsm.StateData import StateData [as 別名]
# 或者: from direct.fsm.StateData.StateData import load [as 別名]
 def load(self):
     StateData.load(self)
     if self.storageDNAFile:
         loader.loadDNAFile(self.dnaStore, self.storageDNAFile)
     self.createNormalSky()
開發者ID:coginvasion,項目名稱:src,代碼行數:7,代碼來源:Hood.py


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