当前位置: 首页>>代码示例>>Python>>正文


Python CogdoFlyingPlayer.__init__方法代码示例

本文整理汇总了Python中CogdoFlyingPlayer.CogdoFlyingPlayer.__init__方法的典型用法代码示例。如果您正苦于以下问题:Python CogdoFlyingPlayer.__init__方法的具体用法?Python CogdoFlyingPlayer.__init__怎么用?Python CogdoFlyingPlayer.__init__使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在CogdoFlyingPlayer.CogdoFlyingPlayer的用法示例。


在下文中一共展示了CogdoFlyingPlayer.__init__方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: __init__

# 需要导入模块: from CogdoFlyingPlayer import CogdoFlyingPlayer [as 别名]
# 或者: from CogdoFlyingPlayer.CogdoFlyingPlayer import __init__ [as 别名]
 def __init__(self, toon, game, level, guiMgr):
     CogdoFlyingPlayer.__init__(self, toon)
     self.defaultTransitions = {'Inactive': ['FreeFly', 'Running'],
      'FreeFly': ['Inactive',
                  'OutOfTime',
                  'Death',
                  'FlyingUp',
                  'Running',
                  'HitWhileFlying',
                  'InWhirlwind'],
      'FlyingUp': ['Inactive',
                   'OutOfTime',
                   'Death',
                   'FreeFly',
                   'Running',
                   'HitWhileFlying',
                   'InWhirlwind'],
      'InWhirlwind': ['Inactive',
                      'OutOfTime',
                      'Death',
                      'FreeFly',
                      'HitWhileFlying'],
      'HitWhileFlying': ['Inactive',
                         'OutOfTime',
                         'Death',
                         'FreeFly',
                         'InWhirlwind'],
      'Death': ['Inactive', 'OutOfTime', 'Spawn'],
      'Running': ['Inactive',
                  'OutOfTime',
                  'FreeFly',
                  'FlyingUp',
                  'Refuel',
                  'WaitingForWin',
                  'HitWhileRunning'],
      'HitWhileRunning': ['Inactive',
                          'OutOfTime',
                          'Death',
                          'Running',
                          'FreeFly'],
      'Spawn': ['Inactive',
                'OutOfTime',
                'Running',
                'WaitingForWin'],
      'OutOfTime': ['Inactive', 'Spawn'],
      'WaitingForWin': ['Inactive', 'Win'],
      'Win': ['Inactive']}
     self.game = game
     self._level = level
     self._guiMgr = guiMgr
     self._inputMgr = CogdoFlyingInputManager()
     self._cameraMgr = CogdoFlyingCameraManager(camera, render, self, self._level)
     self.velocity = Vec3(0.0, 0.0, 0.0)
     self.instantaneousVelocity = Vec3(0.0, 0.0, 0.0)
     self.controlVelocity = Vec3(0.0, 0.0, 0.0)
     self.fanVelocity = Vec3(0.0, 0.0, 0.0)
     self.activeFans = []
     self.fansStillHavingEffect = []
     self.fanIndex2ToonVelocity = {}
     self.legalEagleInterestRequest = {}
     self.activeWhirlwind = None
     self.oldPos = Vec3(0.0, 0.0, 0.0)
     self.checkpointPlatform = None
     self.isHeadInCeiling = False
     self.isToonOnFloor = False
     self.fuel = 0.0
     self.score = 0
     self.postSpawnState = 'Running'
     self.didTimeRunOut = False
     self.hasPressedCtrlYet = False
     self.hasPickedUpFirstPropeller = False
     self.surfacePoint = None
     self.legalEagleHitting = False
     self.propState = None
     self.broadcastPeriod = Globals.AI.BroadcastPeriod
     self.initSfx()
     self.initLocalPlayerIntervals()
     self.initCollisions()
     self.initOrthoWalker()
     self.playerNumber = -1
     self.fuel = 0.0
     self._guiMgr.setFuel(self.fuel)
     self.setCheckpointPlatform(self._level.startPlatform)
开发者ID:NostalgicTTR,项目名称:Toontown-Infinite-2016-Leak,代码行数:85,代码来源:CogdoFlyingLocalPlayer.py


注:本文中的CogdoFlyingPlayer.CogdoFlyingPlayer.__init__方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。