[MIRROR] Maptext 2023: I can see clearly now [MDB IGNORE] (#22100)

* Maptext 2023: I can see clearly now

* skyrat edit

* Update tgstation.dme

---------

Co-authored-by: lessthanthree <83487515+lessthnthree@users.noreply.github.com>
This commit is contained in:
SkyratBot
2023-06-27 21:05:25 -07:00
committed by GitHub
co-authored by lessthanthree
parent 43a452c49f
commit 85faba1a0f
19 changed files with 675 additions and 88 deletions
+6 -2
View File
@@ -13,7 +13,7 @@
/// Approximate height in pixels of an 'average' line, used for height decay
#define CHAT_MESSAGE_APPROX_LHEIGHT 11
/// Max width of chat message in pixels
#define CHAT_MESSAGE_WIDTH 96
#define CHAT_MESSAGE_WIDTH 112
/// The dimensions of the chat message icons
#define CHAT_MESSAGE_ICON_SIZE 9
@@ -145,6 +145,10 @@
if (!ismob(target))
extra_classes |= "small"
// Why are you yelling?
if(copytext_char(text, -2) == "!!")
extra_classes |= SPAN_YELL
var/list/prefixes
// Append radio icon if from a virtual speaker
@@ -171,7 +175,7 @@
var/tgt_color = extra_classes.Find("italics") ? target.chat_color_darkened : target.chat_color
// Approximate text height
var/complete_text = "<span class='center [extra_classes.Join(" ")]' style='color: [tgt_color]'>[owner.say_emphasis(text)]</span>"
var/complete_text = "<span style='color: [tgt_color]'><span class='center [extra_classes.Join(" ")]'>[owner.say_emphasis(text)]</span></span>"
var/mheight
WXH_TO_HEIGHT(owned_by.MeasureText(complete_text, null, CHAT_MESSAGE_WIDTH), mheight)