Adds LOOC to runechat. (#23256)

* adds looc to runechat

* remove hearers

* remove unnecessary parens

* Prevent observers from LOOCing runechat

* Update code/game/verbs/ooc.dm

Co-authored-by: Contrabang <91113370+Contrabang@users.noreply.github.com>

* contra review

---------

Co-authored-by: Contrabang <91113370+Contrabang@users.noreply.github.com>
This commit is contained in:
Luc
2023-11-24 10:32:31 -05:00
committed by GitHub
parent 429981e797
commit 0b4a2bb5cf
3 changed files with 10 additions and 1 deletions
+1
View File
@@ -514,6 +514,7 @@
// Runechat symbol types
#define RUNECHAT_SYMBOL_EMOTE 1
#define RUNECHAT_SYMBOL_LOOC 2
/// Waits at a line of code until X is true
#define UNTIL(X) while(!(X)) sleep(world.tick_lag)
+5 -1
View File
@@ -132,7 +132,11 @@
switch(symbol)
if(RUNECHAT_SYMBOL_EMOTE)
symbol = "<span style='font-size: 9px; color: #3399FF;'>*</span> "
size = size || "small"
size ||= "small"
if(RUNECHAT_SYMBOL_LOOC)
symbol = "<span style='font-size: 5px; color: #6699cc;'><b>\[LOOC]</b></span> "
size ||= "small"
output_color = "gray"
else
symbol = null
+4
View File
@@ -209,6 +209,10 @@ GLOBAL_VAR_INIT(admin_ooc_colour, "#b82e00")
log_looc(msg, src)
mob.create_log(LOOC_LOG, msg)
if(isliving(mob))
for(var/mob/M in viewers(7, mob))
if(M.client?.prefs.toggles2 & PREFTOGGLE_2_RUNECHAT)
M.create_chat_message(mob, msg, FALSE, symbol = RUNECHAT_SYMBOL_LOOC)
var/mob/source = mob.get_looc_source()
var/list/heard = get_mobs_in_view(7, source)