pAI Access Lock Program Fix (#9138)

The modular computer pAI access lock program should properly only show when you have a pAI in your computer.
This commit is contained in:
Geeves
2020-06-29 09:18:17 +02:00
committed by GitHub
parent 780b009d39
commit e4c5d7ff77
12 changed files with 267 additions and 244 deletions

View File

@@ -28,8 +28,15 @@
/datum/computer_file/program/New(var/obj/item/modular_computer/comp)
..()
if(comp && istype(comp))
computer = comp
if(comp)
if(comp == "Compless") // we're software in the air, don't need a computer
return
else if(istype(comp))
computer = comp
else
crash_with("Comp was of the wrong type for [src.filename]")
else
crash_with("Comp was not sent for [src.filename]")
/datum/computer_file/program/Destroy()
computer.idle_threads -= src