//此函数被反射调用的,不能删 public void OnPlayParticle(MoveEditor.MoveAnimationEvent e) { //ParticleEventInfo evt = new MoveEditor.ParticleEventInfo(e.stringParameter); ParticleEventInfo evt = e.EventRef as ParticleEventInfo; PlayParticle(evt._particleProperties); }
public void OnPostFxWarpEvent(MoveEditor.MoveAnimationEvent e) { //PostWarpEventInfo evt = new PostWarpEventInfo(e.stringParameter); PostWarpEventInfo evt = e.EventRef as PostWarpEventInfo; _activePostFxEvents.Add(evt); }
//Animation Event Handlers public void OnSetAnimationSpeed(MoveEditor.MoveAnimationEvent ee) { MoveEditor.AnimationSpeedEventInfo info = ee.EventRef as MoveEditor.AnimationSpeedEventInfo; float variance = UnityEngine.Random.Range(-info.asep._plusMinus, info.asep._plusMinus); variance = (variance < 0 ? -1 : 1) * variance; m_Animator.speed = info._floatParameter + variance; }
public MoveEvent(MoveEditor.MoveAnimationEvent ee, bool isRequired, bool isPlayOnce, bool isPersistent, float endingFrame) { myAnimEvent = ee; required = isRequired; playOnce = isPlayOnce; persistent = isPersistent; endFrame = endingFrame; }
public void OnModifyEnvironmentLighting(MoveEditor.MoveAnimationEvent e) { //EnvironmentLightingEventInfo evt = new EnvironmentLightingEventInfo(e.stringParameter); EnvironmentLightingEventInfo evt = e.EventRef as EnvironmentLightingEventInfo; EnvironmentLightingProperties properties = evt._lightingProperties; float duration = Mathf.Max(properties._multiplyDuration, properties._addDuration); _activeEnvLightingInfo = new EnvLightingInfo(properties, duration); }
private void PlayEffects(ProjectileEvent projectileEvent) { if (_fxHelper == null) { return; } for (int j = 0; j < projectileEvent._particles.Count; ++j) { MoveEditor.ParticleEventInfo particleEventInfo = projectileEvent._particles[j]; // Dirty hack here - if the particle's set to spawn at hit point, we call the player's FXHelper // the reason being that if we don't then the effects will get destroyed since the projectile would likely be deactivated on hit, thus destroying all its fx if (particleEventInfo._particleProperties._spawnAtHitPoint) { MoveEditor.MoveAnimationEvent moveEvent = new MoveEditor.MoveAnimationEvent() { EventRef = particleEventInfo }; _owner.OnHandleMessage("OnPlayParticle", moveEvent); //_owner.FXHelper.PlayParticle(particleEventInfo._particleProperties); } else { _fxHelper.PlayParticle(particleEventInfo._particleProperties); } } for (int j = 0; j < projectileEvent._trails.Count; ++j) { MoveEditor.TrailRendererEventInfo trailEventInfo = projectileEvent._trails[j]; _fxHelper.PlayTrailRenderer(trailEventInfo._trailRendererProperties); } for (int j = 0; j < projectileEvent._dynamicLights.Count; ++j) { MoveEditor.DynamicLightEventInfo dynamicLights = projectileEvent._dynamicLights[j]; _fxHelper.PlayDynamicLight(dynamicLights._dynamicLightProperties); } AttributeData attr = _owner.OnGetAttributeData("IsCurrentAttackCritical"); for (int i = 0; i < projectileEvent._cameraShakes.Count; ++i) { MoveEditor.CameraShakeEventInfo shakeInfo = projectileEvent._cameraShakes[i]; MoveCameraShakeHelper.Shake(shakeInfo, _owner != null && attr.IsCurrentAttackCritical); } }
private void OnClearParticle(MoveEditor.MoveAnimationEvent e) { StopParticle(e.stringParameter, true); }
private void OnStopParticle(MoveEditor.MoveAnimationEvent e) { StopParticle(e.stringParameter); }
private void OnStopDynamicLight(MoveEditor.MoveAnimationEvent e) { StopDynamicLight(e.stringParameter); }
private void OnStopTrailRenderer(MoveEditor.MoveAnimationEvent e) { StopTrailRenderer(e.stringParameter); }
//public void OnPlayCameraShake(MoveEditor.MoveAnimationEvent e) //{ // //var info = new MoveEditor.CameraShakeEventInfo(e.stringParameter); // var info = e.EventRef as CameraShakeEventInfo; // bool isCrit = false; // if (_player == null) // { // _player = GetComponent<Hotfix_LT.Combat.Combatant>(); // } // if (_player != null) // { // isCrit = _player.IsCurrentAttackCritical(); // } // MoveCameraShakeHelper.Shake(info, isCrit); //} public void OnPlayCameraShakeEx(MoveEditor.MoveAnimationEvent e, bool isCrit) { var info = e.EventRef as CameraShakeEventInfo; MoveCameraShakeHelper.Shake(info, isCrit); }
public virtual void OnTriggerCombo(MoveEditor.MoveAnimationEvent ee) { }
public virtual void OnInflictHit(MoveEditor.MoveAnimationEvent ee) { }
public virtual void OnReactionComboEvent(MoveEditor.MoveAnimationEvent ee) { }
public virtual void OnPlayTargetHitReactionEvent(MoveEditor.MoveAnimationEvent ee) { }