You can now rig power cells to explode.

VERY funny.
This commit is contained in:
Pieter-Jan Briers
2021-01-24 16:21:18 +01:00
parent 436694e376
commit 526c3d1ebf
4 changed files with 61 additions and 7 deletions

View File

@@ -53,7 +53,7 @@ namespace Content.Server.GameObjects.Components.Power
/// <summary>
/// If sufficient charge is avaiable on the battery, use it. Otherwise, don't.
/// </summary>
public bool TryUseCharge(float chargeToUse)
public virtual bool TryUseCharge(float chargeToUse)
{
if (chargeToUse >= CurrentCharge)
{
@@ -66,7 +66,7 @@ namespace Content.Server.GameObjects.Components.Power
}
}
public float UseCharge(float toDeduct)
public virtual float UseCharge(float toDeduct)
{
var chargeChangedBy = Math.Min(CurrentCharge, toDeduct);
CurrentCharge -= chargeChangedBy;