本文整理汇总了Python中helpers.CallbackDelayer.CallbackDelayer类的典型用法代码示例。如果您正苦于以下问题:Python CallbackDelayer类的具体用法?Python CallbackDelayer怎么用?Python CallbackDelayer使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了CallbackDelayer类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: __init__
def __init__(self, dataSec, defaultOffset = None, binoculars = None):
CallbackDelayer.__init__(self)
self.__impulseOscillator = None
self.__movementOscillator = None
self.__noiseOscillator = None
self.__dynamicCfg = CameraDynamicConfig()
self.__accelerationSmoother = None
self.__readCfg(dataSec)
if binoculars is None:
return
else:
self.__cam = BigWorld.FreeCamera()
self.__zoom = self.__cfg['zoom']
self.__curSense = 0
self.__curScrollSense = 0
self.__waitVehicleCallbackId = None
self.__onChangeControlMode = None
self.__aimingSystem = SniperAimingSystem(dataSec)
self.__binoculars = binoculars
self.__defaultAimOffset = defaultOffset or Vector2()
self.__crosshairMatrix = createCrosshairMatrix(offsetFromNearPlane=self.__dynamicCfg['aimMarkerDistance'])
self.__prevTime = BigWorld.time()
self.__autoUpdateDxDyDz = Vector3(0, 0, 0)
if BattleReplay.g_replayCtrl.isPlaying:
BattleReplay.g_replayCtrl.setDataCallback('applyZoom', self.__applyZoom)
return
示例2: destroy
def destroy(self):
CallbackDelayer.destroy(self)
self.disable()
self.__activeSelector = None
self.__cam.destroy()
self.__aih = None
return
示例3: destroy
def destroy(self):
CallbackDelayer.destroy(self)
if self.__cloud is not None:
self.__cloud.destroy()
self.__evtManager.clear()
self.__state = GasAttackState.DONE
return
示例4: __init__
def __init__(self, dataSec, aim):
CallbackDelayer.__init__(self)
TimeDeltaMeter.__init__(self)
self.__shiftKeySensor = None
self.__movementOscillator = None
self.__impulseOscillator = None
self.__noiseOscillator = None
self.__dynamicCfg = CameraDynamicConfig()
self.__accelerationSmoother = None
self.__readCfg(dataSec)
self.__cam = None
self.__aim = None
self.__onChangeControlMode = None
self.__aimingSystem = None
self.__curSense = 0
self.__curScrollSense = 0
self.__postmortemMode = False
self.__vehiclesToCollideWith = set()
self.__focalPointDist = 1.0
self.__autoUpdateDxDyDz = Vector3(0.0)
self.__defaultAimOffset = (0.0, 0.0)
if aim is None:
return
else:
self.__aim = weakref.proxy(aim)
self.__cam = BigWorld.HomingCamera()
aimOffset = self.__aim.offset()
self.__cam.aimPointClipCoords = Vector2(aimOffset)
self.__defaultAimOffset = (aimOffset[0], aimOffset[1])
return
示例5: __init__
def __init__(self, dataSec, defaultOffset = None):
CallbackDelayer.__init__(self)
TimeDeltaMeter.__init__(self)
self.__shiftKeySensor = None
self.__movementOscillator = None
self.__impulseOscillator = None
self.__noiseOscillator = None
self.__dynamicCfg = CameraDynamicConfig()
self.__accelerationSmoother = None
self.__readCfg(dataSec)
self.__onChangeControlMode = None
self.__aimingSystem = None
self.__curSense = 0
self.__curScrollSense = 0
self.__postmortemMode = False
self.__vehiclesToCollideWith = set()
self.__focalPointDist = 1.0
self.__autoUpdateDxDyDz = Vector3(0.0)
self.__updatedByKeyboard = False
if defaultOffset is not None:
self.__defaultAimOffset = defaultOffset
self.__cam = BigWorld.HomingCamera()
self.__cam.aimPointClipCoords = defaultOffset
else:
self.__defaultAimOffset = Vector2()
self.__cam = None
return
示例6: destroy
def destroy(self):
_SPGFlashGunMarker.destroy(self)
CallbackDelayer.destroy(self)
self.__desiredShotInfoFunc = None
self.__trajectoryDrawer.visible = False
self.__trajectoryDrawer = None
return
示例7: destroy
def destroy(self):
self.__trackScrollCtl = None
if self.__vehicle is not None:
self.deactivate()
self.__destroySystems()
ComponentSystem.destroy(self)
self.__typeDesc = None
self.highlighter.destroy()
if self.__vibrationsCtrl is not None:
self.__vibrationsCtrl.destroy()
self.__vibrationsCtrl = None
if self.__lightFxCtrl is not None:
self.__lightFxCtrl.destroy()
self.__lightFxCtrl = None
if self.__auxiliaryFxCtrl is not None:
self.__auxiliaryFxCtrl.destroy()
self.__auxiliaryFxCtrl = None
if self.__boundEffects is not None:
self.__boundEffects.destroy()
self.__vehicleStickers = None
self.onModelChanged = None
if self.__crashedTracksCtrl is not None:
self.__crashedTracksCtrl.destroy()
self.__crashedTracksCtrl = None
self.__chassisOcclusionDecal.destroy()
self.__chassisOcclusionDecal = None
self.__chassisShadowForwardDecal.destroy()
self.__chassisShadowForwardDecal = None
self.__compoundModel = None
CallbackDelayer.destroy(self)
return
示例8: destroy
def destroy(self):
CallbackDelayer.destroy(self)
if self.__manualSound is not None:
self.__manualSound.stopAll()
self.__manualSound = None
self.__stateTable = None
return
示例9: __init__
def __init__(self, dataSec, aim, binoculars):
CallbackDelayer.__init__(self)
self.__impulseOscillator = None
self.__movementOscillator = None
self.__noiseOscillator = None
self.__dynamicCfg = CameraDynamicConfig()
self.__accelerationSmoother = None
self.__readCfg(dataSec)
if aim is None or binoculars is None:
return
else:
self.__cam = BigWorld.FreeCamera()
self.__zoom = self.__cfg['zoom']
self.__curSense = 0
self.__curScrollSense = 0
self.__waitVehicleCallbackId = None
self.__onChangeControlMode = None
self.__aimingSystem = SniperAimingSystem(dataSec)
self.__aim = weakref.proxy(aim)
self.__binoculars = binoculars
self.__defaultAimOffset = self.__aim.offset()
self.__defaultAimOffset = (self.__defaultAimOffset[0], self.__defaultAimOffset[1])
self.__crosshairMatrix = createCrosshairMatrix(offsetFromNearPlane=self.__dynamicCfg['aimMarkerDistance'])
self.__prevTime = BigWorld.time()
self.__autoUpdateDxDyDz = Vector3(0, 0, 0)
return
示例10: __init__
def __init__(self, dataSec, defaultOffset = None):
CallbackDelayer.__init__(self)
TimeDeltaMeter.__init__(self)
self.__shiftKeySensor = None
self.__movementOscillator = None
self.__impulseOscillator = None
self.__noiseOscillator = None
self.__dynamicCfg = CameraDynamicConfig()
self.__accelerationSmoother = None
self.__readCfg(dataSec)
self.__onChangeControlMode = None
self.__aimingSystem = None
self.__curSense = 0
self.__curScrollSense = 0
self.__postmortemMode = False
self.__vehiclesToCollideWith = set()
self.__focalPointDist = 1.0
self.__autoUpdateDxDyDz = Vector3(0.0)
self.__updatedByKeyboard = False
if defaultOffset is not None:
self.__defaultAimOffset = defaultOffset
self.__cam = BigWorld.HomingCamera(self.__adCfg['enable'])
if self.__adCfg['enable']:
self.__cam.initAdvancedCollider(self.__adCfg['fovRatio'], self.__adCfg['rollbackSpeed'], self.__adCfg['minimalCameraDistance'], self.__adCfg['speedThreshold'], self.__adCfg['minimalVolume'])
for group_name in VOLUME_GROUPS_NAMES:
self.__cam.addVolumeGroup(self.__adCfg['volumeGroups'][group_name])
self.__cam.aimPointClipCoords = defaultOffset
else:
self.__defaultAimOffset = Vector2()
self.__cam = None
return
示例11: __init__
def __init__(self):
CallbackDelayer.__init__(self)
ComponentSystem.__init__(self)
self.turretMatrix = Math.WGAdaptiveMatrixProvider()
self.gunMatrix = Math.WGAdaptiveMatrixProvider()
self.__vehicle = None
self.__filter = None
self.__originalFilter = None
self.__typeDesc = None
self.__waterHeight = -1.0
self.__isInWater = False
self.__isUnderWater = False
self.__splashedWater = False
self.__vibrationsCtrl = None
self.__lightFxCtrl = None
self.__auxiliaryFxCtrl = None
self.__fashion = None
self.__crashedTracksCtrl = None
self.__gunRecoil = None
self.__currentDamageState = VehicleDamageState()
self.__loadingProgress = 0
self.__effectsPlayer = None
self.__engineMode = (0, 0)
self.__swingMoveFlags = 0
self.__currTerrainMatKind = [-1] * _MATKIND_COUNT
self.__leftLightRotMat = None
self.__rightLightRotMat = None
self.__leftFrontLight = None
self.__rightFrontLight = None
self.__prevVelocity = None
self.__prevTime = None
self.__isPillbox = False
self.__chassisOcclusionDecal = OcclusionDecal()
self.__chassisShadowForwardDecal = ShadowForwardDecal()
self.__splodge = None
self.__vehicleStickers = None
self.onModelChanged = Event()
self.__speedInfo = Math.Vector4(0.0, 0.0, 0.0, 0.0)
self.__wasOnSoftTerrain = False
self.__vehicleMatrixProv = None
self.__leftTrackScroll = 0.0
self.__rightTrackScroll = 0.0
self.__distanceFromPlayer = 0.0
self.__fashions = None
self.__compoundModel = None
self.__boundEffects = None
self.__swingingAnimator = None
self.__splineTracks = None
self.__customEffectManager = None
self.__trackScrollCtl = BigWorld.PyTrackScroll()
self.__weaponEnergy = 0.0
self.__activated = False
self.__systemStarted = False
self.__vID = 0
self.__isAlive = True
self.__isTurretDetached = False
self.__trackFashionSet = False
self.__periodicTimerID = None
self.__wasDeactivated = False
return
示例12: __init__
def __init__(self):
CallbackDelayer.__init__(self)
self.__alwaysShowAimKey = None
self.__showMarkersKey = None
sec = self._readCfg()
self.onCameraChanged = Event()
self.onPostmortemVehicleChanged = Event()
self.onSetReloading = Event()
self.onSetReloadingPercents = Event()
self.__isArenaStarted = False
self.__isStarted = False
self.__targeting = _Targeting()
self.__vertScreenshotCamera = _VertScreenshotCamera()
self.__ctrls = dict()
self.__killerVehicleID = None
self.__isAutorotation = True
self.__prevModeAutorotation = None
self.__isSPG = False
self.__isATSPG = False
self.__setupCtrls(sec)
self.__curCtrl = self.__ctrls[_CTRLS_FIRST]
self.ctrlModeName = _CTRLS_FIRST
self.__isDetached = False
self.__waitObserverCallback = None
self.__observerVehicle = None
return
示例13: __init__
def __init__(self, updatePeriod = 0.0):
CallbackDelayer.__init__(self)
self.__updatePeriod = updatePeriod
self.__currentSpeedState = self.__SPEED_IDLE
self.__keyOffCalled = False
self.__manualSound = None
self.__gearSound = None
self.__gearDamagedParam = None
self.__manGearDamagedParam = None
self.__gearKeyOffParam = None
self.__stateTable = ((None,
self.__startManualSound,
self.__initHighSpeed,
None),
(self.__stopManualSound,
None,
self.__initHighSpeed,
None),
(self.__stopManualSound,
self.__startManualSoundFromFast,
None,
None),
(self.__stopGearSoundPlaying,
self.__startManualSoundFromFast,
None,
self.__checkGearSound))
self.__init_sound()
return
示例14: destroy
def destroy(self):
CallbackDelayer.destroy(self)
self.__cam = None
if self.__aim is not None:
self.__aim.destroy()
self.__aim = None
return
示例15: __init__
def __init__(self, configDataSec):
CallbackDelayer.__init__(self)
TimeDeltaMeter.__init__(self, time.clock)
self.__cam = BigWorld.FreeCamera()
self.__cam.invViewProvider = Math.MatrixProduct()
self.__ypr = Math.Vector3()
self.__position = Math.Vector3()
self.__defaultFov = BigWorld.projection().fov
self.__velocity = Math.Vector3()
self.__isVerticalVelocitySeparated = False
self.__yprVelocity = Math.Vector3()
self.__zoomVelocity = 0.0
self.__inertiaEnabled = False
self.__movementInertia = None
self.__rotationInertia = None
self.__movementSensor = None
self.__verticalMovementSensor = None
self.__rotationSensor = None
self.__zoomSensor = None
self.__targetRadiusSensor = None
self.__mouseSensitivity = 0.0
self.__scrollSensitivity = 0.0
self.__rotateAroundPointEnabled = False
self.__rotationRadius = 40.0
self.__alignerToLand = _AlignerToLand()
self.__predefinedVelocities = {}
self.__predefinedVerticalVelocities = {}
self.__keySwitches = {}
self.__readCfg(configDataSec)
self.__aim = None
self.__basisMProv = _VehicleBounder()
self.__entityPicker = _VehiclePicker()
return