mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-10 18:22:39 +00:00
Updated OldUI for Computers to be usable by ghosts
This commit is contained in:
@@ -101,6 +101,20 @@
|
||||
return text
|
||||
|
||||
|
||||
/obj/machinery/computer/attack_ghost(user as mob)
|
||||
return src.attack_hand(user)
|
||||
|
||||
/obj/machinery/computer/attack_hand(user as mob)
|
||||
/* Observers can view computers, but not actually use them via Topic*/
|
||||
if(istype(user, /mob/dead/observer)) return 0
|
||||
return ..()
|
||||
|
||||
/obj/machinery/computer/Topic(href, href_list)
|
||||
/* Can't use topic as observer by default */
|
||||
if(istype(usr, /mob/dead/observer)) return 0
|
||||
return ..()
|
||||
|
||||
|
||||
/obj/machinery/computer/attackby(I as obj, user as mob)
|
||||
if(istype(I, /obj/item/weapon/screwdriver) && circuit)
|
||||
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
|
||||
|
||||
@@ -50,7 +50,9 @@
|
||||
else
|
||||
usr << "[src.current.name] selected for law changes."
|
||||
return
|
||||
|
||||
|
||||
attack_ghost(user as mob)
|
||||
return 1
|
||||
|
||||
|
||||
/obj/machinery/computer/borgupload
|
||||
@@ -83,3 +85,6 @@
|
||||
else
|
||||
usr << "[src.current.name] selected for law changes."
|
||||
return
|
||||
|
||||
attack_ghost(user as mob)
|
||||
return 1
|
||||
|
||||
@@ -9,6 +9,10 @@
|
||||
var/one_time_use = 0 //Used for one-time-use teleport cards (such as clown planet coordinates.)
|
||||
//Setting this to 1 will set src.locked to null after a player enters the portal and will not allow hand-teles to open portals to that location.
|
||||
|
||||
/* Ghosts can't use this */
|
||||
/obj/machinery/computer/attack_ghost(user as mob)
|
||||
return 1
|
||||
|
||||
/obj/machinery/computer/teleporter/New()
|
||||
src.id = "[rand(1000, 9999)]"
|
||||
..()
|
||||
@@ -80,9 +84,11 @@
|
||||
/obj/machinery/teleport/station/attack_ai()
|
||||
src.attack_hand()
|
||||
|
||||
/obj/machinery/computer/teleporter/attack_hand()
|
||||
if(stat & (NOPOWER|BROKEN))
|
||||
return
|
||||
/obj/machinery/computer/teleporter/attack_hand(user as mob)
|
||||
if(..()) return
|
||||
|
||||
/* Ghosts can't use this one because it's a direct selection */
|
||||
if(istype(user, /mob/dead/observer)) return
|
||||
|
||||
var/list/L = list()
|
||||
var/list/areaindex = list()
|
||||
|
||||
Reference in New Issue
Block a user