diff --git a/code/__DEFINES/machines.dm b/code/__DEFINES/machines.dm index b137fadbb21..b8b6c4cffdf 100644 --- a/code/__DEFINES/machines.dm +++ b/code/__DEFINES/machines.dm @@ -27,7 +27,9 @@ #define IDLE_POWER_USE 1 #define ACTIVE_POWER_USE 2 +///Base global power consumption for idling machines #define BASE_MACHINE_IDLE_CONSUMPTION 100 +///Base global power consumption for active machines #define BASE_MACHINE_ACTIVE_CONSUMPTION (BASE_MACHINE_IDLE_CONSUMPTION * 10) /// Bitflags for a machine's preferences on when it should start processing. For use with machinery's `processing_flags` var. diff --git a/code/game/machinery/_machinery.dm b/code/game/machinery/_machinery.dm index 9959271ce60..b5439f9ff78 100644 --- a/code/game/machinery/_machinery.dm +++ b/code/game/machinery/_machinery.dm @@ -143,6 +143,8 @@ var/last_used_time = 0 /// Mobtype of last user. Typecast to [/mob/living] for initial() usage var/mob/living/last_user_mobtype + ///Multiplier for power consumption. + var/machine_power_rectifier = 1 /obj/machinery/Initialize(mapload) if(!armor) diff --git a/code/modules/power/power.dm b/code/modules/power/power.dm index 02a0ee9089f..60ae485aff3 100644 --- a/code/modules/power/power.dm +++ b/code/modules/power/power.dm @@ -93,6 +93,7 @@ // increment the power usage stats for an area /obj/machinery/proc/use_power(amount, chan = power_channel) + amount = max(amount * machine_power_rectifier, 0) // make sure we don't use negative power var/area/A = get_area(src) // make sure it's in an area A?.use_power(amount, chan)