From d8540cdbd9cc5e0d029671fe8d47ee137fbc9f55 Mon Sep 17 00:00:00 2001 From: Pieter-Jan Briers Date: Wed, 30 May 2018 17:05:06 +0200 Subject: [PATCH] Comments are important. --- .../GameObjects/Components/Power/PowerDevice.cs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Content.Server/GameObjects/Components/Power/PowerDevice.cs b/Content.Server/GameObjects/Components/Power/PowerDevice.cs index df973b45345..3ec986c6d63 100644 --- a/Content.Server/GameObjects/Components/Power/PowerDevice.cs +++ b/Content.Server/GameObjects/Components/Power/PowerDevice.cs @@ -192,6 +192,10 @@ namespace Content.Server.GameObjects.Components.Power } } + /// + /// Updates the state of whether or not this device is powered, + /// and fires off events if said state has changed. + /// private void UpdatePowered() { var oldPowered = Powered; @@ -319,6 +323,10 @@ namespace Content.Server.GameObjects.Components.Power ConnectToBestProvider(); } + /// + /// Process mechanism to keep track of internal battery and power status. + /// + /// Time since the last process frame. internal virtual void ProcessInternalPower(float frametime) { if (Owner.TryGetComponent(out var storage) && storage.CanDeductCharge(Load))