Persist weapon runtime state in checkpoints
This commit is contained in:
parent
3c4fe6fd10
commit
f98f650ab5
10 changed files with 287 additions and 8 deletions
|
|
@ -59,6 +59,11 @@ public class InstantWeapon : Weapon, IProgressBehavior, IEventBehavior
|
|||
{
|
||||
get => _ammo;
|
||||
}
|
||||
public int BurstRemaining => _burstRemaining;
|
||||
public float BurstTimer => _burstTimer;
|
||||
public float BurstInterval => _burstInterval;
|
||||
public float CooldownProgress => _cooldown;
|
||||
public bool CoolingDown => _coolingDown;
|
||||
public virtual float Progress => saturate(_cooldown);
|
||||
|
||||
public event Action OnReloadBegin;
|
||||
|
|
@ -197,4 +202,4 @@ public class InstantWeapon : Weapon, IProgressBehavior, IEventBehavior
|
|||
Trigger();
|
||||
base.Activate();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue