mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-24 05:23:22 +01:00
Merge pull request #11508 from PsiOmegaDelta/151122-GhostlyInteraction
Ghosts can now view any object with a NanoUI interface.
This commit is contained in:
@@ -96,15 +96,6 @@
|
||||
text = replacetext(text, "\n", "<BR>")
|
||||
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/attackby(I as obj, user as mob)
|
||||
if(istype(I, /obj/item/weapon/screwdriver) && circuit)
|
||||
playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1)
|
||||
|
||||
@@ -10,10 +10,6 @@
|
||||
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/teleporter/attack_ghost(user as mob)
|
||||
return 1
|
||||
|
||||
/obj/machinery/computer/teleporter/New()
|
||||
src.id = "[rand(1000, 9999)]"
|
||||
..()
|
||||
|
||||
@@ -82,9 +82,6 @@ var/global/list/default_medbay_channels = list(
|
||||
for (var/ch_name in channels)
|
||||
secure_radio_connections[ch_name] = radio_controller.add_object(src, radiochannels[ch_name], RADIO_CHAT)
|
||||
|
||||
/obj/item/device/radio/attack_ghost(mob/user)
|
||||
return ui_interact(user)
|
||||
|
||||
/obj/item/device/radio/attack_self(mob/user as mob)
|
||||
user.set_machine(src)
|
||||
interact(user)
|
||||
|
||||
@@ -117,6 +117,9 @@
|
||||
if(!ai_in_use && !is_in_use)
|
||||
in_use = 0
|
||||
|
||||
/obj/attack_ghost(mob/user)
|
||||
ui_interact(user)
|
||||
|
||||
/obj/proc/interact(mob/user)
|
||||
return
|
||||
|
||||
|
||||
@@ -9,10 +9,12 @@
|
||||
/mob/proc/default_can_use_topic(var/src_object)
|
||||
return STATUS_CLOSE // By default no mob can do anything with NanoUI
|
||||
|
||||
/mob/dead/observer/default_can_use_topic()
|
||||
/mob/dead/observer/default_can_use_topic(var/src_object)
|
||||
if(can_admin_interact())
|
||||
return STATUS_INTERACTIVE // Admins are more equal
|
||||
return STATUS_UPDATE // Ghosts can view updates
|
||||
return STATUS_INTERACTIVE // Admins are more equal
|
||||
if(!client || get_dist(src_object, src) > client.view) // Preventing ghosts from having a million windows open by limiting to objects in range
|
||||
return STATUS_CLOSE
|
||||
return STATUS_UPDATE // Ghosts can view updates
|
||||
|
||||
/mob/living/silicon/pai/default_can_use_topic(var/src_object)
|
||||
if((src_object == src || src_object == radio) && !stat)
|
||||
|
||||
@@ -725,11 +725,6 @@
|
||||
// do APC interaction
|
||||
src.interact(user)
|
||||
|
||||
/obj/machinery/power/apc/attack_ghost(user as mob)
|
||||
if(stat & (BROKEN|MAINT))
|
||||
return
|
||||
return ui_interact(user)
|
||||
|
||||
/obj/machinery/power/apc/interact(mob/user)
|
||||
if(!user)
|
||||
return
|
||||
|
||||
@@ -227,10 +227,7 @@
|
||||
|
||||
|
||||
/obj/machinery/power/smes/attack_ai(mob/user)
|
||||
add_fingerprint(user)
|
||||
ui_interact(user)
|
||||
|
||||
/obj/machinery/power/smes/attack_ghost(mob/user)
|
||||
add_hiddenprint(user)
|
||||
ui_interact(user)
|
||||
|
||||
/obj/machinery/power/smes/attack_hand(mob/user)
|
||||
|
||||
Reference in New Issue
Block a user