Skip to content

Power Patches

NathanIkola edited this page Mar 13, 2022 · 2 revisions

AddStandbyInspectMessage

Patched Type Patched Method Call Frequency
CompPower CompInspectStringExtra Every tick that you have the inspect panel open

Description

This patch simply replaces the power drawing message in the inspect panel with "On Standby" when the building is on standby.


DisableBasePowerDrawOnGet

Patched Type Patched Method Call Frequency
CompPowerTrader PowerOutput Tick

Description

This patch modifies the power output of a building based on whether or not it's enabled. If it's enabled, it pulls the active power draw rate, and if it's inactive it pulls the standby power draw rate (or 0 for lights). The active/standby rates are configured in the mod settings.


DisableBuildingsOnSpawn

Patched Type Patched Method Call Frequency
Building SpawnSetup Once any time a building spawns

Description

Disables all tables when they spawn into the map for any reason. If the building is a light, it performs a check to see if they should be on or off, and enables/disables itself appropriately. Additionally, if the building is not a light, it also removes the KeepOnComp so that you don't see the "Keep On" gizmo on anything except lights.


DisableThingsInRoomsOnSpawn

Patched Type Patched Method Call Frequency
RegionAndRoomUpdater FloodAndSetRooms Once when a map loads

Description

It's possible that lights misbehave due to inconsistent load ordering and sometimes enable/disable incorrectly when loading from a save. To combat this, this patch performs a final check to a room once loaded and enables or disables all lights in the room as appropriate to make sure that lights are well-behaved on loading.


RechargeablePatch

Patched Type Patched Method Call Frequency
CompRechargeable CompTick Tick

Description

This patch handles rechargeable buildings (such as the neural supercharger) and allows them to pull power at their active rate until charged, then pull power at their standby rate.