public void PlaySlowDownSound(NodeAddedEvent evt, VulcanSlowDownNode weapon) { if (!weapon.vulcanSlowDown.IsAfterShooting) { AudioSource soundSource = weapon.vulcanSlowDownAfterSpeedUpSoundEffect.SoundSource; soundSource.time = weapon.vulcanSlowDownAfterSpeedUpSoundEffect.StartTimePerSec + weapon.vulcanSlowDownAfterSpeedUpSoundEffect.AdditionalStartTimeOffset; VulcanFadeSoundBehaviour component = soundSource.gameObject.GetComponent <VulcanFadeSoundBehaviour>(); component.fadeDuration = weapon.vulcanWeaponState.State * weapon.vulcanWeapon.SlowDownTime; component.enabled = true; this.PlayNextSound(soundSource, weapon.vulcanSoundManager); } }
public void RemoveVulcanShootingCameraShakerInstance(NodeAddedEvent evt, VulcanSlowDownNode vulcan) { vulcan.Entity.RemoveComponent <VulcanShootingCameraShakerInstanceComponent>(); }
public void RemoveGyroscopeComponent(NodeRemoveEvent evt, VulcanSlowDownForNRNode nr, [JoinSelf] VulcanSlowDownNode vulcan) { vulcan.Entity.RemoveComponent <VulcanGyroscopeEnabledComponent>(); }
public void StartSlowDown(NodeAddedEvent evt, VulcanSlowDownNode slowDownState, [Context, JoinByTank] ReadyVulcanTurbineAnimationNode weapon, [Context, JoinByTank] ActiveTankNode tank) { weapon.vulcanTurbineAnimation.StartSlowDown(); }