mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-26 06:22:26 +01:00
Megaphones now create floating chat and use accent/lang (#22942)
Megaphones now use your accent, language, and create floating text when used. <img width="2560" height="1400" alt="dreamseeker_V1ntU7aL2j" src="https://github.com/user-attachments/assets/36828048-9e5b-4c6d-bad9-974d8880adef" /> Port of https://github.com/Baystation12/Baystation12/pull/35232 but only in spirit.
This commit is contained in:
@@ -154,11 +154,16 @@
|
||||
|
||||
if(length(text_to_display) > LANGCHAT_LONGEST_TEXT)
|
||||
text_to_display = copytext_char(text_to_display, 1, LANGCHAT_LONGEST_TEXT + 1) + "..."
|
||||
if(styles.Find("emote"))
|
||||
if("emote" in styles)
|
||||
styles.Remove("emote")
|
||||
use_mob_style = FALSE
|
||||
var/image/r_icon = image('icons/mob/chat_icons.dmi', icon_state = "emote")
|
||||
text_to_display = "\icon[r_icon]&zwsp;[text_to_display]"
|
||||
if("radio" in styles)
|
||||
styles.Remove("radio")
|
||||
use_mob_style = FALSE
|
||||
var/image/r_icon = image('icons/mob/chat_icons.dmi', icon_state = "radio")
|
||||
text_to_display = "\icon[r_icon]&zwsp;[text_to_display]"
|
||||
|
||||
return "<span class='center [styles.Join(" ")] [use_mob_style ? langchat_styles : ""] langchat'>[text_to_display]</span>"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user