performance

This commit is contained in:
Purpose
2018-09-16 11:12:56 +01:00
parent 85e35bcba9
commit 1fa1949f8f
2 changed files with 6 additions and 10 deletions
@@ -185,7 +185,7 @@
set name = "Destroy RCDs"
set desc = "Detonate all RCDs on the station, while sparing onboard cyborg RCDs."
if(stat || malf_cooldown)
if(stat || malf_cooldown > world.time)
return
for(var/obj/item/rcd/RCD in rcd_list)
@@ -193,9 +193,7 @@
RCD.detonate_pulse()
to_chat(src, "<span class='danger'>RCD detonation pulse emitted.</span>")
malf_cooldown = 1
spawn(100)
malf_cooldown = 0
malf_cooldown = world.time + 100
/datum/AI_Module/large/mecha_domination
@@ -454,7 +452,7 @@
set name = "Reactivate Cameranet"
set category = "Malfunction"
if(stat || malf_cooldown)
if(stat || malf_cooldown > world.time)
return
var/fixedcams = 0 //Tells the AI how many cams it fixed. Stats are fun.
@@ -477,9 +475,7 @@
break
to_chat(src, "<span class='notice'>Diagnostic complete! Operations completed: [fixedcams].</span>")
malf_cooldown = 1
spawn(30) //Lag protection
malf_cooldown = 0
malf_cooldown = world.time + 30
/datum/AI_Module/large/upgrade_cameras
+2 -2
View File
@@ -69,7 +69,7 @@ var/list/ai_verbs_default = list(
var/control_disabled = 0 // Set to 1 to stop AI from interacting via Click() -- TLE
var/malfhacking = 0 // More or less a copy of the above var, so that malf AIs can hack and still get new cyborgs -- NeoFite
var/malf_cooldown = 0 //Cooldown var for malf modules
var/malf_cooldown = 0 //Cooldown var for malf modules, stores a worldtime + cooldown
var/obj/machinery/power/apc/malfhack = null
var/explosive = 0 //does the AI explode when it dies?
@@ -1250,7 +1250,7 @@ var/list/ai_verbs_default = list(
else
to_chat(src, "<span class='warning'>Target is not on or near any active cameras on the station.</span>")
/mob/living/silicon/ai/handle_fire()
return