mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2025-12-29 11:31:38 +00:00
Fixes AI cards/mechs, with least bad method.
This commit is contained in:
@@ -204,9 +204,11 @@
|
||||
return
|
||||
|
||||
/obj/mecha/see_emote(mob/living/M, text)
|
||||
if(M == occupant && M.client)
|
||||
var/rendered = "<span class='message'>[text]</span></span>"
|
||||
if(occupant && occupant.client)
|
||||
world << "MECHA NAMED [src.name] HEARD [M.name] DO [text]!"
|
||||
var/rendered = "<span class='message'>[text]</span>"
|
||||
occupant.show_message(rendered, 2)
|
||||
world << "SEE_EMOTE() WAS RAN ON [src.name]!"
|
||||
..()
|
||||
|
||||
////////////////////////////
|
||||
|
||||
@@ -174,8 +174,8 @@
|
||||
update_icon()
|
||||
|
||||
/obj/item/device/aicard/see_emote(mob/living/M, text)
|
||||
if(carded_ai.client)
|
||||
var/rendered = "<span class='message'>[text]</span></span>"
|
||||
if(carded_ai && carded_ai.client)
|
||||
var/rendered = "<span class='message'>[text]</span>"
|
||||
carded_ai.show_message(rendered, 2)
|
||||
..()
|
||||
/*
|
||||
|
||||
@@ -313,7 +313,7 @@
|
||||
|
||||
|
||||
/obj/item/device/paicard/see_emote(mob/living/M, text)
|
||||
if(pai.client)
|
||||
var/rendered = "<span class='message'>[text]</span></span>"
|
||||
if(pai && pai.client)
|
||||
var/rendered = "<span class='message'>[text]</span>"
|
||||
pai.show_message(rendered, 2)
|
||||
..()
|
||||
@@ -136,5 +136,6 @@
|
||||
mo.show_message(rendered, 2)
|
||||
*/
|
||||
return
|
||||
|
||||
/obj/proc/see_emote(mob/M as mob, text, var/emote_type)
|
||||
return
|
||||
|
||||
@@ -50,7 +50,10 @@
|
||||
|
||||
// Type 1 (Visual) emotes are sent to anyone in view of the item
|
||||
if (m_type & 1)
|
||||
for (var/mob/O in viewers(src, null))
|
||||
//for (var/mob/O in viewers(src, null))
|
||||
for (var/mob/O in viewers(get_turf(src), null)) //This may break people with x-ray being able to see emotes across walls,
|
||||
//but this saves many headaches down the road, involving mechs and pAIs.
|
||||
//x-ray is so rare these days anyways.
|
||||
|
||||
if(O.status_flags & PASSEMOTES)
|
||||
|
||||
@@ -68,7 +71,7 @@
|
||||
O.see_emote(src, message, 1)
|
||||
|
||||
// Type 2 (Audible) emotes are sent to anyone in hear range
|
||||
// of the *LOCATION* -- this is important for pAIs to be heard
|
||||
// of the *LOCATION* -- this is important for AIs/pAIs to be heard
|
||||
else if (m_type & 2)
|
||||
for (var/mob/O in hearers(get_turf(src), null))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user