Machinery: Always use update_use_power()

This commit is contained in:
Atermonera
2020-03-23 23:21:10 -04:00
committed by VirgoBot
parent f60a39dd4d
commit cbb40196fc
145 changed files with 1645 additions and 285 deletions
+4 -4
View File
@@ -297,7 +297,7 @@ var/list/ai_verbs_default = list(
/obj/machinery/ai_powersupply
name="Power Supply"
active_power_usage=50000 // Station AIs use significant amounts of power. This, when combined with charged SMES should mean AI lasts for 1hr without external power.
use_power = 2
use_power = USE_POWER_ACTIVE
power_channel = EQUIP
var/mob/living/silicon/ai/powered_ai = null
invisibility = 100
@@ -325,14 +325,14 @@ var/list/ai_verbs_default = list(
qdel(src)
return
if(powered_ai.APU_power)
use_power = 0
update_use_power(USE_POWER_OFF)
return
if(!powered_ai.anchored)
loc = powered_ai.loc
use_power = 0
update_use_power(USE_POWER_OFF)
use_power(50000) // Less optimalised but only called if AI is unwrenched. This prevents usage of wrenching as method to keep AI operational without power. Intellicard is for that.
if(powered_ai.anchored)
use_power = 2
update_use_power(USE_POWER_ACTIVE)
/mob/living/silicon/ai/proc/pick_icon()
set category = "AI Settings"
@@ -11,7 +11,7 @@
density = 1
anchored = 1
use_power = 1
use_power = USE_POWER_IDLE
idle_power_usage = 20
active_power_usage = 5000