mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-28 06:27:26 +01:00
Convert most spans to defines (#31080)
* spanish? * aaaagain * keep maptext * Update robot_items.dm * Update span_defines.dm * compiles * Update silicon_mob.dm * compile
This commit is contained in:
@@ -29,7 +29,7 @@
|
||||
if(!is_advanced)
|
||||
var/turf/T = get_turf(ui_host())
|
||||
if(!T || !is_level_reachable(T.z))
|
||||
to_chat(usr, "<span class='warning'><b>Unable to establish a connection</b>: You're too far away from the station!</span>")
|
||||
to_chat(usr, SPAN_WARNING("<b>Unable to establish a connection</b>: You're too far away from the station!"))
|
||||
return FALSE
|
||||
|
||||
. = TRUE
|
||||
|
||||
@@ -51,5 +51,5 @@
|
||||
//Auto flush if we use this verb inside a disposal chute.
|
||||
if(istype(R.loc, /obj/machinery/disposal))
|
||||
var/obj/machinery/disposal/D = R.loc
|
||||
to_chat(R, "<span class='notice'>[D] acknowledges your signal.</span>")
|
||||
to_chat(R, SPAN_NOTICE("[D] acknowledges your signal."))
|
||||
D.flush_count = D.flush_every_ticks
|
||||
|
||||
@@ -80,7 +80,7 @@
|
||||
if("Gamma")
|
||||
D = new /datum/response_team/gamma
|
||||
else
|
||||
to_chat(usr, "<span class='userdanger'>Invalid ERT type.</span>")
|
||||
to_chat(usr, SPAN_USERDANGER("Invalid ERT type."))
|
||||
return
|
||||
GLOB.ert_request_answered = TRUE
|
||||
var/slots_list = list()
|
||||
|
||||
@@ -57,10 +57,10 @@ GLOBAL_DATUM_INIT(ghost_hud_panel, /datum/ui_module/ghost_hud_panel, new)
|
||||
|
||||
if("ahud_on")
|
||||
if(!GLOB.configuration.general.allow_antag_hud && !ghost.client.holder)
|
||||
to_chat(ghost, "<span class='warning'>Admins have disabled this for this round.</span>")
|
||||
to_chat(ghost, SPAN_WARNING("Admins have disabled this for this round."))
|
||||
return FALSE
|
||||
if(jobban_isbanned(ghost, "AntagHUD"))
|
||||
to_chat(ghost, "<span class='danger'>You have been banned from using this feature.</span>")
|
||||
to_chat(ghost, SPAN_DANGER("You have been banned from using this feature."))
|
||||
return FALSE
|
||||
// Check if this is the first time they're turning on Antag HUD.
|
||||
if(!check_rights(R_ADMIN | R_MOD, FALSE) && !ghost.is_roundstart_observer() && GLOB.configuration.general.restrict_antag_hud_rejoin && !ghost.has_ahudded())
|
||||
|
||||
@@ -41,7 +41,7 @@ RESTRICT_TYPE(/datum/ui_module/id_card_modifier)
|
||||
if("reg")
|
||||
var/temp_name = reject_bad_name(input(usr, "Who is this ID for?", "ID Card Renaming", card.registered_name), TRUE)
|
||||
if(!temp_name)
|
||||
to_chat(usr, "<span class='warning'>Rejecting invalid name `[temp_name]`.</span>")
|
||||
to_chat(usr, SPAN_WARNING("Rejecting invalid name `[temp_name]`."))
|
||||
return
|
||||
card.registered_name = temp_name
|
||||
card.regenerate_name()
|
||||
@@ -76,13 +76,13 @@ RESTRICT_TYPE(/datum/ui_module/id_card_modifier)
|
||||
if("grant_region")
|
||||
var/region = text2num(params["region"])
|
||||
if(isnull(region) || region < REGION_GENERAL)
|
||||
to_chat(usr, "<span class='warning'>Rejecting invalid region `[region]`.</span>")
|
||||
to_chat(usr, SPAN_WARNING("Rejecting invalid region `[region]`."))
|
||||
return
|
||||
card.access |= get_region_accesses(region)
|
||||
if("deny_region")
|
||||
var/region = text2num(params["region"])
|
||||
if(isnull(region) || region < REGION_GENERAL)
|
||||
to_chat(usr, "<span class='warning'>Rejecting invalid region `[region]`.</span>")
|
||||
to_chat(usr, SPAN_WARNING("Rejecting invalid region `[region]`."))
|
||||
return
|
||||
card.access -= get_region_accesses(region)
|
||||
if("clear_all")
|
||||
|
||||
@@ -98,7 +98,7 @@
|
||||
var/datum/ai_law/AL = locate(params["edit_law"]) in owner.laws.all_laws()
|
||||
// Dont allow non-admins to edit their own malf laws
|
||||
if(istype(AL, /datum/ai_law/zero) && (!check_rights(R_ADMIN)))
|
||||
to_chat(ui.user, "<span class='warning'>You can't edit that law.</span>")
|
||||
to_chat(ui.user, SPAN_WARNING("You can't edit that law."))
|
||||
return
|
||||
if(AL)
|
||||
var/new_law = tgui_input_text(ui.user, "Enter new law. Leaving the field blank will cancel the edit.", "Edit Law", AL.law)
|
||||
@@ -111,7 +111,7 @@
|
||||
var/datum/ai_law/AL = locate(params["delete_law"]) in owner.laws.all_laws()
|
||||
// Dont allow non-admins to delete their own malf laws
|
||||
if(istype(AL, /datum/ai_law/zero) && (!check_rights(R_ADMIN)))
|
||||
to_chat(ui.user, "<span class='warning'>You can't delete that law.</span>")
|
||||
to_chat(ui.user, SPAN_WARNING("You can't delete that law."))
|
||||
return
|
||||
if(AL && is_malf(ui.user))
|
||||
owner.delete_law(AL)
|
||||
@@ -138,15 +138,15 @@
|
||||
current_view = 0
|
||||
|
||||
if("notify_laws")
|
||||
to_chat(owner, "<span class='danger'>Law Notice</span>")
|
||||
to_chat(owner, SPAN_DANGER("Law Notice"))
|
||||
owner.laws.show_laws(owner)
|
||||
if(is_ai(owner))
|
||||
var/mob/living/silicon/ai/AI = owner
|
||||
for(var/mob/living/silicon/robot/R in AI.connected_robots)
|
||||
to_chat(R, "<span class='danger'>Law Notice</span>")
|
||||
to_chat(R, SPAN_DANGER("Law Notice"))
|
||||
R.laws.show_laws(R)
|
||||
if(ui.user != owner)
|
||||
to_chat(ui.user, "<span class='notice'>Laws displayed.</span>")
|
||||
to_chat(ui.user, SPAN_NOTICE("Laws displayed."))
|
||||
|
||||
|
||||
/datum/ui_module/law_manager/ui_state(mob/user)
|
||||
|
||||
@@ -131,7 +131,7 @@ GLOBAL_LIST(ui_logins)
|
||||
state.rank = state.id.assignment
|
||||
state.access = state.id.access
|
||||
else
|
||||
to_chat(usr, "<span class='warning'>Access Denied</span>")
|
||||
to_chat(usr, SPAN_WARNING("Access Denied"))
|
||||
return
|
||||
else if(login_type == LOGIN_TYPE_AI && is_ai(usr))
|
||||
state.name = usr.name
|
||||
|
||||
@@ -150,7 +150,7 @@
|
||||
if(length_char(params["entry"]) > max_length)
|
||||
CRASH("[usr] typed a text string longer than the max length")
|
||||
if(encode && (length_char(html_encode(params["entry"])) > max_length))
|
||||
to_chat(usr, "<span class='notice'>Your message was clipped due to special character usage.</span>")
|
||||
to_chat(usr, SPAN_NOTICE("Your message was clipped due to special character usage."))
|
||||
set_entry(params["entry"])
|
||||
closed = TRUE
|
||||
SStgui.close_uis(src)
|
||||
|
||||
@@ -70,7 +70,7 @@
|
||||
*/
|
||||
/datum/tgui_panel/proc/on_initialize_timed_out()
|
||||
// Currently does nothing but sending a message to old chat.
|
||||
SEND_TEXT(client, "<span class='userdanger'>Failed to load fancy chat, click <a href='byond://?src=[UID()];reload_tguipanel=1'>HERE</a> to attempt to reload it.</span>")
|
||||
SEND_TEXT(client, SPAN_USERDANGER("Failed to load fancy chat, click <a href='byond://?src=[UID()];reload_tguipanel=1'>HERE</a> to attempt to reload it."))
|
||||
|
||||
/**
|
||||
* private
|
||||
@@ -99,7 +99,7 @@
|
||||
return TRUE
|
||||
if(type == "audio/protected")
|
||||
if(!admins_warned)
|
||||
message_admins("<span class='notice'>Audio returned a protected playback error, likely due to being copyrighted.</span>")
|
||||
message_admins(SPAN_NOTICE("Audio returned a protected playback error, likely due to being copyrighted."))
|
||||
admins_warned = TRUE
|
||||
addtimer(VARSET_CALLBACK(src, admins_warned, FALSE), 10 SECONDS)
|
||||
return TRUE
|
||||
|
||||
@@ -52,5 +52,5 @@
|
||||
continue
|
||||
window.reinitialize()
|
||||
refreshed_count++
|
||||
to_chat(usr, "<span class='notice'>TGUI windows refreshed - [refreshed_count].<br>If you have blank window - restart the game, or open previous TGUI window.</span>")
|
||||
to_chat(usr, SPAN_NOTICE("TGUI windows refreshed - [refreshed_count].<br>If you have blank window - restart the game, or open previous TGUI window."))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user