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


Python StateData.enter方法代碼示例

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


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

示例1: enter

# 需要導入模塊: from direct.fsm.StateData import StateData [as 別名]
# 或者: from direct.fsm.StateData.StateData import enter [as 別名]
 def enter(self):
     StateData.enter(self)
     self.avMoney = base.localAvatar.getMoney()
     self.origHealth = base.localAvatar.getHealth()
     self.window = ShopWindow(self, image='phase_4/maps/FrameBlankA.jpg')
     self.window.setup()
     self.window.setOKCommand(self.confirmPurchase)
     self.window.setCancelCommand(self.cancelPurchase)
     self.window.makePages(self.distShop.getItems())
     self.window.setPage(0)
     self.healCooldownDoneSfx = base.loadSfx(self.healCooldownDoneSoundPath)
開發者ID:coginvasion,項目名稱:src,代碼行數:13,代碼來源:Shop.py

示例2: enter

# 需要導入模塊: from direct.fsm.StateData import StateData [as 別名]
# 或者: from direct.fsm.StateData.StateData import enter [as 別名]
 def enter(self):
     if self.entered:
         return
     self.entered = 1
     StateData.enter(self)
     render.hide()
     base.setBackgroundColor(0.05, 0.15, 0.4)
     self.book_img = OnscreenImage(image=self.book_texture, scale=(2, 1, 1.5))
     self.book_open.play()
     if base.localAvatar.getAdminToken() > -1:
         self.fsm.request('adminPage')
     else:
         self.fsm.request('mapPage')
開發者ID:coginvasion,項目名稱:src,代碼行數:15,代碼來源:ShtickerBook.py

示例3: enter

# 需要導入模塊: from direct.fsm.StateData import StateData [as 別名]
# 或者: from direct.fsm.StateData.StateData import enter [as 別名]
 def enter(self, requestStatus):
     StateData.enter(self)
     hoodId = requestStatus['hoodId']
     zoneId = requestStatus['zoneId']
     rootZone = ZoneUtil.getZoneId(hoodId)
     if base.localAvatar.getLastHood() != rootZone and hoodId != CIGlobals.MinigameArea:
         base.localAvatar.b_setLastHood(rootZone)
     if not base.localAvatar.hasDiscoveredHood(rootZone):
         hoodsDiscovered = list(base.localAvatar.getHoodsDiscovered())
         hoodsDiscovered.append(rootZone)
         base.localAvatar.b_setHoodsDiscovered(hoodsDiscovered)
     text = self.getHoodText(zoneId)
     self.titleText = OnscreenText(text, fg=self.titleColor, font=CIGlobals.getMickeyFont(), scale=0.15, pos=(0, -0.65))
     self.titleText.hide()
開發者ID:coginvasion,項目名稱:src,代碼行數:16,代碼來源:Hood.py

示例4: enter

# 需要導入模塊: from direct.fsm.StateData import StateData [as 別名]
# 或者: from direct.fsm.StateData.StateData import enter [as 別名]
 def enter(self, requestStatus):
     StateData.enter(self)
     if base.localAvatar.zoneId < 61000:
         self.findAndMakeLinkTunnels()
     self.fsm.enterInitialState()
     messenger.send('enterSafeZone')
     self.setState(requestStatus['where'], requestStatus)
     partyGate = self.geom.find('**/prop_party_gate_DNARoot')
     if not partyGate.isEmpty():
         partyGate.removeNode()
     del partyGate
     petShop = self.geom.find('**/prop_pet_shop_DNARoot')
     if not petShop.isEmpty():
         petShop.removeNode()
     del petShop
開發者ID:coginvasion,項目名稱:src,代碼行數:17,代碼來源:SafeZoneLoader.py

示例5: enter

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

示例6: enter

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

示例7: enter

# 需要導入模塊: from direct.fsm.StateData import StateData [as 別名]
# 或者: from direct.fsm.StateData.StateData import enter [as 別名]
 def enter(self, requestStatus):
     StateData.enter(self)
     self.findAndMakeLinkTunnels(requestStatus)
     self.fsm.enterInitialState()
     self.setState(requestStatus['where'], requestStatus)
開發者ID:coginvasion,項目名稱:src,代碼行數:7,代碼來源:TownLoader.py

示例8: enter

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

示例9: enter

# 需要導入模塊: from direct.fsm.StateData import StateData [as 別名]
# 或者: from direct.fsm.StateData.StateData import enter [as 別名]
 def enter(self):
     StateData.enter(self)
     base.transitions.noTransitions()
     self.avChooseFSM.request('getToonData')
開發者ID:coginvasion,項目名稱:src,代碼行數:6,代碼來源:AvChooser.py

示例10: enter

# 需要導入模塊: from direct.fsm.StateData import StateData [as 別名]
# 或者: from direct.fsm.StateData.StateData import enter [as 別名]
 def enter(self, requestStatus):
     StateData.enter(self)
     self._requestStatus = requestStatus
     base.localAvatar.b_setAnimState('off')
     self.fsm.request('waitForQuietZoneResponse')
開發者ID:coginvasion,項目名稱:src,代碼行數:7,代碼來源:QuietZoneState.py


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