public void StartShotIfPossible(EarlyUpdateEvent evt, DiscreteWeaponMagazineControllerNode discreteWeaponMagazineController, [JoinByTank] AutopilotTankNode autopilotTank) { if (autopilotTank.autopilotWeaponController.Fire && (discreteWeaponMagazineController.cooldownTimer.CooldownTimerSec <= 0f)) { base.ScheduleEvent <BeforeShotEvent>(discreteWeaponMagazineController); base.ScheduleEvent <ShotPrepareEvent>(discreteWeaponMagazineController); } }
public void StartShotIfPossible(EarlyUpdateEvent evt, SelfTankNode selfTank, [JoinByTank] DiscreteWeaponMagazineControllerNode discreteWeaponMagazineController) { if ((discreteWeaponMagazineController.cooldownTimer.CooldownTimerSec <= 0f) && InputManager.CheckAction(ShotActions.SHOT)) { base.ScheduleEvent <BeforeShotEvent>(discreteWeaponMagazineController); base.ScheduleEvent <ShotPrepareEvent>(discreteWeaponMagazineController); } }