本文整理汇总了Python中toontown.suit.Suit类的典型用法代码示例。如果您正苦于以下问题:Python Suit类的具体用法?Python Suit怎么用?Python Suit使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了Suit类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: load
def load(self):
Place.Place.load(self)
self.parentFSM.getStateNamed('suitInterior').addChild(self.fsm)
self.townBattle = TownBattle.TownBattle('town-battle-done')
self.townBattle.load()
for i in range(1, 3):
Suit.loadSuits(i)
示例2: load
def load(self):
Place.Place.load(self)
self.parentFSM.getStateNamed("cogdoInterior").addChild(self.fsm)
self.townBattle = TownBattle.TownBattle("town-battle-done")
self.townBattle.load()
for i in xrange(1, 3):
Suit.loadSuits(i)
示例3: load
def load(self, zoneId):
TownLoader.TownLoader.load(self, zoneId)
Suit.loadSuits(1)
filepath = '%s/toonland/playground/oz/dna' % __filebase__
dnaFile = ('%s/outdoor_zone_' % filepath) + str(self.canonicalBranchZone) + '.dna'
self.createHood(dnaFile)
taskMgr.doMethodLater(0.2, self._OZTownLoader__loadPythonImplementation, 'OZ-LPI')
示例4: unload
def unload(self):
BattlePlace.BattlePlace.unload(self)
self.parentFSM.getStateNamed('cogHQBossBattle').removeChild(self.fsm)
del self.parentFSM
del self.fsm
self.ignoreAll()
for i in xrange(1, 3):
Suit.unloadSuits(i)
示例5: load
def load(self, zoneId):
self.parentFSMState.addChild(self.fsm)
self.battleMusic = base.loadMusic('phase_9/audio/bgm/encntr_suit_winning.ogg')
self.townBattle = TownBattle.TownBattle(self.townBattleDoneEvent)
self.townBattle.load()
Suit.loadSuits(3)
self.loadPlaceGeom(zoneId)
self.music = base.loadMusic(self.musicFile)
示例6: load
def load(self, zoneId):
TownLoader.TownLoader.load(self, zoneId)
Suit.loadSuits(3)
dnaFile = 'phase_8/dna/the_burrrgh_' + str(self.canonicalBranchZone) + '.pdna'
self.createHood(dnaFile)
self.windSound = map(base.loadSfx, ['phase_8/audio/sfx/SZ_TB_wind_1.ogg',
'phase_8/audio/sfx/SZ_TB_wind_2.ogg',
'phase_8/audio/sfx/SZ_TB_wind_3.ogg'])
self.snow = BattleParticles.loadParticleFile('snowdisk.ptf')
self.snow.setPos(0, 0, 5)
self.snowRender = self.geom.attachNewNode('snowRender')
self.snowRender.setDepthWrite(0)
self.snowRender.setBin('fixed', 1)
示例7: unload
def unload(self):
Place.Place.unload(self)
self.parentFSM.getStateNamed('suitInterior').removeChild(self.fsm)
del self.parentFSM
del self.fsm
self.ignoreAll()
ModelPool.garbageCollect()
TexturePool.garbageCollect()
self.townBattle.unload()
self.townBattle.cleanup()
del self.townBattle
for i in range(1, 3):
Suit.unloadSuits(i)
示例8: unload
def unload(self):
self.unloadPlaceGeom()
self.parentFSMState.removeChild(self.fsm)
del self.parentFSMState
del self.fsm
self.townBattle.unload()
self.townBattle.cleanup()
del self.townBattle
del self.battleMusic
Suit.unloadSuits(3)
Suit.unloadSkelDialog()
del self.hood
ModelPool.garbageCollect()
TexturePool.garbageCollect()
示例9: load
def load(self):
if self.isLoaded == 1:
return None
self.isLoaded = 1
gui = loader.loadModel('phase_3/models/gui/dialog_box_buttons_gui')
guiButton = loader.loadModel('phase_3/models/gui/quit_button')
self.head = Suit.attachSuitHead(self, self.suitName)
z = self.head.getZ()
self.head.setPos(-0.4, -0.1, z + 0.14)
self.suitLabel = DirectLabel(parent=self, relief=None, text=self.suitFullName, text_font=ToontownGlobals.getSuitFont(), pos=(-0.4, 0, -0.085), scale=0.07)
closeButtonImage = (gui.find('**/CloseBtn_UP'), gui.find('**/CloseBtn_DN'), gui.find('**/CloseBtn_Rllvr'))
buttonImage = (guiButton.find('**/QuitBtn_UP'), guiButton.find('**/QuitBtn_DN'), guiButton.find('**/QuitBtn_RLVR'))
disabledColor = Vec4(0.5, 0.5, 0.5, 1)
base.cr.lmao = self
self.summonBuildingButton = DirectButton(parent=self, relief=None, text=TTLocalizer.SummonDlgButton1, image=buttonImage, image_scale=(1.7, 1, 1), image3_color=disabledColor, text_scale=0.06, text_pos=(0, -0.01), pos=(0.3, 0, 0.35), command=self.issueSummons, extraArgs=['building'])
self.summonInvasionButton = DirectButton(parent=self, relief=None, text=TTLocalizer.SummonDlgButton2, image=buttonImage, image_scale=(1.7, 1, 1), image3_color=disabledColor, text_scale=0.06, text_pos=(0, -0.01), pos=(0.3, 0, 0.225), command=self.issueSummons, extraArgs=['invasion'])
self.summonCogdoButton = DirectButton(parent=self, relief=None, text=TTLocalizer.SummonDlgButton3, image=buttonImage, image_scale=(1.7, 1, 1), image3_color=disabledColor, text_scale=0.06, text_pos=(0, -0.01), pos=(0.3, 0, 0.1), command=self.issueSummons, extraArgs=['cogdo'])
self.summonSkelInvasionButton = DirectButton(parent=self, relief=None, text=TTLocalizer.SummonDlgButton4, image=buttonImage, image_scale=(1.7, 1, 1), image3_color=disabledColor, text_scale=0.051, text_pos=(0, -0.01), pos=(0.3, 0, -0.025), command=self.issueSummons, extraArgs=['skelinvasion'])
self.summonWaiterInvasionButton = DirectButton(parent=self, relief=None, text=TTLocalizer.SummonDlgButton5, image=buttonImage, image_scale=(1.7, 1, 1), image3_color=disabledColor, text_scale=0.056, text_pos=(0, -0.01), pos=(0.3, 0, -0.15), command=self.issueSummons, extraArgs=['waiterinvasion'])
self.summonV2InvasionButton = DirectButton(parent=self, relief=None, text=TTLocalizer.SummonDlgButton6, image=buttonImage, image_scale=(1.7, 1, 1), image3_color=disabledColor, text_scale=0.048, text_pos=(0, -0.01), pos=(0.3, 0, -0.275), command=self.issueSummons, extraArgs=['v2invasion'])
self.statusLabel = DirectLabel(parent=self, relief=None, text='', text_wordwrap=12, pos=(0.3, 0, 0.3), scale=0.07)
self.cancel = DirectButton(parent=self, relief=None, image=closeButtonImage, pos=(0.7, 0, -0.366), command=self.__cancel)
gui.removeNode()
guiButton.removeNode()
self.hide()
return
示例10: load
def load(self):
if self.isLoaded == 1:
return None
self.isLoaded = 1
gui = loader.loadModel('phase_3/models/gui/dialog_box_buttons_gui')
guiButton = loader.loadModel('phase_3/models/gui/quit_button')
self.head = Suit.attachSuitHead(self, self.suitName)
z = self.head.getZ()
self.head.setPos(-0.40000000000000002, -0.10000000000000001, z + 0.20000000000000001)
self.suitLabel = DirectLabel(parent = self, relief = None, text = self.suitFullName, text_font = ToontownGlobals.getSuitFont(), pos = (-0.40000000000000002, 0, 0), scale = 0.070000000000000007)
closeButtonImage = (gui.find('**/CloseBtn_UP'), gui.find('**/CloseBtn_DN'), gui.find('**/CloseBtn_Rllvr'))
buttonImage = (guiButton.find('**/QuitBtn_UP'), guiButton.find('**/QuitBtn_DN'), guiButton.find('**/QuitBtn_RLVR'))
disabledColor = Vec4(0.5, 0.5, 0.5, 1)
self.summonSingleButton = DirectButton(parent = self, relief = None, text = TTL.SummonDlgButton1, image = buttonImage, image_scale = (1.7, 1, 1), image3_color = disabledColor, text_scale = 0.059999999999999998, text_pos = (0, -0.01), pos = (0.29999999999999999, 0, 0.25), command = self.issueSummons, extraArgs = [
'single'])
self.summonBuildingButton = DirectButton(parent = self, relief = None, text = TTL.SummonDlgButton2, image = buttonImage, image_scale = (1.7, 1, 1), image3_color = disabledColor, text_scale = 0.059999999999999998, text_pos = (0, -0.01), pos = (0.29999999999999999, 0, 0.125), command = self.issueSummons, extraArgs = [
'building'])
self.summonInvasionButton = DirectButton(parent = self, relief = None, text = TTL.SummonDlgButton3, image = buttonImage, image_scale = (1.7, 1, 1), image3_color = disabledColor, text_scale = 0.059999999999999998, text_pos = (0, -0.01), pos = (0.29999999999999999, 0, 0.0), command = self.issueSummons, extraArgs = [
'invasion'])
self.statusLabel = DirectLabel(parent = self, relief = None, text = '', text_wordwrap = 12, pos = (0.29999999999999999, 0, 0.25), scale = 0.070000000000000007)
self.cancel = DirectButton(parent = self, relief = None, image = closeButtonImage, pos = (0.69999999999999996, 0, -0.10000000000000001), command = self._SummonCogDialog__cancel)
gui.removeNode()
guiButton.removeNode()
self.hide()
示例11: addSuitHead
def addSuitHead(self, panel, suitName):
panelIndex = self.panels.index(panel)
shadow = panel.attachNewNode('shadow')
shadowModel = self.shadowModels[panelIndex]
shadowModel.copyTo(shadow)
coords = SHADOW_SCALE_POS[panelIndex]
shadow.setScale(coords[0])
shadow.setPos(coords[1], coords[2], coords[3])
panel.shadow = shadow
panel.head = Suit.attachSuitHead(panel, suitName)
示例12: load
def load(self, zoneId):
TownLoader.TownLoader.load(self, zoneId)
Suit.loadTutorialSuit()
dnaFile = 'phase_3.5/dna/tutorial_street.dna'
self.createHood(dnaFile, loadStorage=0)
self.alterDictionaries()
示例13: setSuitHead
def setSuitHead(self, suitName):
self.head = Suit.attachSuitHead(self, suitName)
self.head.setX(0.1)
self.head.setZ(0.01)
示例14: unload
def unload(self):
TownLoader.TownLoader.unload(self)
Suit.unloadSuits(2)
示例15: load
def load(self, zoneId):
TownLoader.TownLoader.load(self, zoneId)
Suit.loadSuits(2)
dnaFile = 'phase_6/dna/donalds_dock_' + str(self.canonicalBranchZone) + '.pdna'
self.createHood(dnaFile)