Cleanup BatterySystem (#41298)
* cleanup * fix fixtures * this belongs into the next PR * review * misc --------- Co-authored-by: ArtisticRoomba <145879011+ArtisticRoomba@users.noreply.github.com>
This commit is contained in:
@@ -358,13 +358,13 @@ namespace Content.Server.Power.EntitySystems
|
||||
|
||||
if (requireBattery)
|
||||
{
|
||||
_battery.SetCharge(uid, battery.CurrentCharge - apcBattery.IdleLoad * frameTime, battery);
|
||||
_battery.SetCharge((uid, battery), battery.CurrentCharge - apcBattery.IdleLoad * frameTime);
|
||||
}
|
||||
// Otherwise try to charge the battery
|
||||
else if (powered && !_battery.IsFull(uid, battery))
|
||||
else if (powered && !_battery.IsFull((uid, battery)))
|
||||
{
|
||||
apcReceiver.Load += apcBattery.BatteryRechargeRate * apcBattery.BatteryRechargeEfficiency;
|
||||
_battery.SetCharge(uid, battery.CurrentCharge + apcBattery.BatteryRechargeRate * frameTime, battery);
|
||||
_battery.SetCharge((uid, battery), battery.CurrentCharge + apcBattery.BatteryRechargeRate * frameTime);
|
||||
}
|
||||
|
||||
// Enable / disable the battery if the state changed
|
||||
|
||||
Reference in New Issue
Block a user