diff --git a/code/game/atoms.dm b/code/game/atoms.dm index 9339b16a8fa..0c34ecf1f01 100644 --- a/code/game/atoms.dm +++ b/code/game/atoms.dm @@ -2106,14 +2106,14 @@ //Update the screentip to reflect what we're hoverin over /atom/MouseEntered(location, control, params) . = ..() - // Statusbar - status_bar_set_text(usr, name) // Screentips - if(usr?.hud_used) - if(!usr.hud_used.screentips_enabled || (flags_1 & NO_SCREENTIPS_1)) - usr.hud_used.screentip_text.maptext = "" + var/datum/hud/active_hud = usr.hud_used + if(active_hud) + if(!active_hud.screentips_enabled || (flags_1 & NO_SCREENTIPS_1)) + active_hud.screentip_text.maptext = "" else - usr.hud_used.screentip_text.maptext = MAPTEXT("[name]") + //We inline a MAPTEXT() here, because there's no good way to statically add to a string like this + active_hud.screentip_text.maptext = "[name]" /// Gets a merger datum representing the connected blob of objects in the allowed_types argument /atom/proc/GetMergeGroup(id, list/allowed_types) diff --git a/code/modules/status_bar/status_bar.dm b/code/modules/status_bar/status_bar.dm deleted file mode 100644 index 8e3431b5fd3..00000000000 --- a/code/modules/status_bar/status_bar.dm +++ /dev/null @@ -1,20 +0,0 @@ -/*! - * Copyright (c) 2021 Aleksej Komarov - * SPDX-License-Identifier: MIT - */ - -/client/var/status_bar_prev_text = "" - -/** - * Set status bar text for the provided `target`. - * - * Target can be either of `/client` or `/mob`. - */ -/proc/status_bar_set_text(target, text) - var/client/client = CLIENT_FROM_VAR(target) - // Stop a winset call if text didn't change. - if(!client || client.status_bar_prev_text == text) - return - client.status_bar_prev_text = text - winset(client, "mapwindow.status_bar", - "text=[url_encode(text)]&is-visible=[!!text]") diff --git a/interface/skin.dmf b/interface/skin.dmf index 168dd6eb06c..1880d4071bb 100644 --- a/interface/skin.dmf +++ b/interface/skin.dmf @@ -104,6 +104,7 @@ window "mapwindow" anchor2 = -1,-1 saved-params = "pos;size;is-minimized;is-maximized" is-pane = true + on-status = ".winset \"status_bar.text=[[*]]\" " elem "map" type = MAP pos = 0,0 @@ -121,7 +122,7 @@ window "mapwindow" pos = 0,464 size = 280x16 anchor1 = 0,100 - is-visible = false + is-visible = true text = "" align = left background-color = #222222 diff --git a/tgstation.dme b/tgstation.dme index 61a41c5833a..ee318e1766c 100644 --- a/tgstation.dme +++ b/tgstation.dme @@ -3796,7 +3796,6 @@ #include "code\modules\station_goals\dna_vault.dm" #include "code\modules\station_goals\shield.dm" #include "code\modules\station_goals\station_goal.dm" -#include "code\modules\status_bar\status_bar.dm" #include "code\modules\surgery\amputation.dm" #include "code\modules\surgery\blood_filter.dm" #include "code\modules\surgery\bone_mending.dm"