Пример #1
0
 /// <summary>
 /// Called every frame, if not on mobile, gets shoot axis values from input
 /// </summary>
 protected virtual void SetShootAxis()
 {
     if (!IsMobile && InputDetectionActive)
     {
         ShootAxis          = MMInput.ProcessAxisAsButton(_axisShoot, Threshold.y, ShootAxis, MMInput.AxisTypes.Positive);
         SecondaryShootAxis = MMInput.ProcessAxisAsButton(_axisShootSecondary, -Threshold.y, SecondaryShootAxis, MMInput.AxisTypes.Negative);
     }
 }
Пример #2
0
 protected override void SetShootAxis()
 {
     base.SetShootAxis();
     if (IsMobile || !InputDetectionActive)
     {
         return;
     }
     ShootAxes[0] = ShootAxis;
     ShootAxes[1] = SecondaryShootAxis;
     for (var i = 2; i < MaximumNumberOfWeapons; i++)
     {
         ShootAxes[i] = MMInput.ProcessAxisAsButton(_axesShoot[i], Threshold.y, ShootAxes[i]);
     }
 }