Various Tweaks & Fixes (#15857)

* Stuff

* Grammar reviewer review

Co-authored-by: Sean Williams <12197162+S34NW@users.noreply.github.com>

* Shuttle call HTML fix

And multiline announcements too, à la #15645.

The clean_input() was causing the message to be encoded twice, and only decoded once. Removing it still encodes the string.

* Loadout revert

Co-authored-by: Sean Williams <12197162+S34NW@users.noreply.github.com>
This commit is contained in:
SabreML
2021-05-24 16:29:07 +01:00
committed by GitHub
co-authored by Sean Williams
parent 311c0b5317
commit 4960f5440c
16 changed files with 20 additions and 17 deletions
+2 -2
View File
@@ -122,12 +122,12 @@
icon_state = "too_much_oxy"
/obj/screen/alert/not_enough_nitro
name = "Choking (No N)"
name = "Choking (No N2)"
desc = "You're not getting enough nitrogen. Find some good air before you pass out!"
icon_state = "not_enough_nitro"
/obj/screen/alert/too_much_nitro
name = "Choking (N)"
name = "Choking (N2)"
desc = "There's too much nitrogen in the air, and you're breathing it in! Find some good air before you pass out!"
icon_state = "too_much_nitro"
-2
View File
@@ -135,8 +135,6 @@ SUBSYSTEM_DEF(shuttle)
to_chat(user, "The emergency shuttle has been disabled by Centcom.")
return
call_reason = trim(html_encode(call_reason))
if(length(call_reason) < CALL_SHUTTLE_REASON_LENGTH)
to_chat(user, "Reason is too short. [CALL_SHUTTLE_REASON_LENGTH] character minimum.")
return
+2 -2
View File
@@ -21,7 +21,7 @@
if(!usr.mind.miming)
to_chat(usr, "<span class='notice'>You must dedicate yourself to silence first.</span>")
return
invocation = "<B>[usr.real_name]</B> looks as if a wall is in front of [usr.p_them()]."
invocation = "<B>[usr.name]</B> looks as if a wall is in front of [usr.p_them()]."
else
invocation_type ="none"
..()
@@ -86,7 +86,7 @@
if(!usr.mind.miming)
to_chat(usr, "<span class='notice'>You must dedicate yourself to silence first.</span>")
return
invocation = "<B>[usr.real_name]</B> looks as if a blockade is in front of [usr.p_them()]."
invocation = "<B>[usr.name]</B> looks as if a blockade is in front of [usr.p_them()]."
else
invocation_type ="none"
..()
+1 -1
View File
@@ -290,7 +290,7 @@ You are weak to holy things and starlight. Don't go into space and avoid the Cha
draining = null
return
add_attack_logs(owner, H, "vampirebit & is draining their blood.", ATKLOG_ALMOSTALL)
owner.visible_message("<span class='danger'>[owner] grabs [H]'s neck harshly and sinks in [owner.p_their()] fangs!</span>", "<span class='danger'>You sink your fangs into [H] and begin to drain [owner.p_their()] blood.</span>", "<span class='notice'>You hear a soft puncture and a wet sucking noise.</span>")
owner.visible_message("<span class='danger'>[owner] grabs [H]'s neck harshly and sinks in [owner.p_their()] fangs!</span>", "<span class='danger'>You sink your fangs into [H] and begin to drain [H.p_their()] blood.</span>", "<span class='notice'>You hear a soft puncture and a wet sucking noise.</span>")
if(!iscarbon(owner))
H.LAssailant = null
else
@@ -147,7 +147,7 @@
message_cooldown = world.time + 600 //One minute
if("callshuttle")
var/input = clean_input("Please enter the reason for calling the shuttle.", "Shuttle Call Reason.","")
var/input = input("Please enter the reason for calling the shuttle.", "Shuttle Call Reason.") as null|message
if(!input || ..() || !is_authenticated(usr))
return
call_shuttle_proc(usr, input)
@@ -410,7 +410,7 @@
else
menu_state=value
/proc/call_shuttle_proc(mob/user, reason)
/proc/call_shuttle_proc(mob/user, reason, sanitized = FALSE)
if(GLOB.sent_strike_team == 1)
to_chat(user, "<span class='warning'>Central Command will not allow the shuttle to be called. Consider all contracts terminated.</span>")
return
@@ -427,6 +427,9 @@
to_chat(user, "<span class='warning'>Under directive 7-10, [station_name()] is quarantined until further notice.</span>")
return
if(!sanitized)
reason = trim_strip_html_properly(reason, allow_lines = TRUE)
SSshuttle.requestEvac(user, reason)
log_game("[key_name(user)] has called the shuttle.")
message_admins("[key_name_admin(user)] has called the shuttle.", 1)
@@ -69,7 +69,6 @@
togglelock(user)
/obj/structure/closet/secure_closet/AltClick(mob/user)
..()
if(Adjacent(user))
togglelock(user)
+2 -1
View File
@@ -397,7 +397,8 @@
return TRUE
/obj/structure/window/AltClick(mob/user)
if(fulltile) // Can't rotate these.
return ..()
if(user.incapacitated())
to_chat(user, "<span class='warning'>You can't do that right now!</span>")
return
+2 -2
View File
@@ -424,9 +424,9 @@
..()
/obj/item/clothing/glasses/thermal/monocle
name = "thermoncle"
name = "thermonocle"
desc = "A thermal monocle."
icon_state = "thermoncle"
icon_state = "thermonocle"
flags_cover = null //doesn't protect eyes because it's a monocle, duh
/obj/item/clothing/glasses/thermal/eyepatch
+3 -1
View File
@@ -127,11 +127,13 @@ GLOBAL_LIST_EMPTY(karma_spenders)
continue
if(M == src)
continue
if(M.get_preference(PREFTOGGLE_DISABLE_KARMA))
continue
if(!isobserver(src) && isNonCrewAntag(M))
continue // Don't include special roles for non-observers, because players use it to meta
karma_list += M
if(!karma_list.len)
if(!length(karma_list))
to_chat(usr, "<span class='warning'>There's no-one to spend your karma on.</span>")
return
+1 -1
View File
@@ -93,7 +93,7 @@
for(var/P in GLOB.dead_mob_list)
var/mob/M = P
if((M.client?.prefs.toggles2 & PREFTOGGLE_2_DEATHMESSAGE) && (isobserver(M) || M.stat == DEAD))
to_chat(M, "<span class='deadsay'><b>[mind.name]</b> has died at <b>[area_name]</b>. (<a href='?src=[M.UID()];jump=\ref[src]'>JMP</a>)</span>")
to_chat(M, "<span class='deadsay'><b>[mind.name]</b> has died at <b>[area_name]</b>. (<a href='?src=[M.UID()];jump=\ref[T]'>JMP</a>)</span>")
if(SSticker && SSticker.mode)
SSticker.mode.check_win()
+1 -1
View File
@@ -539,7 +539,7 @@ GLOBAL_LIST_INIT(ai_verbs_default, list(
if(check_unable(AI_CHECK_WIRELESS))
return
var/input = clean_input("Please enter the reason for calling the shuttle.", "Shuttle Call Reason.","")
var/input = input("Please enter the reason for calling the shuttle.", "Shuttle Call Reason.") as null|message
if(!input || stat)
return
+1 -1
View File
@@ -92,7 +92,7 @@
return 0
for(var/obj/effect/ebeam/medical/B in turf)// Don't cross the str-beams!
if(B.owner != current_beam)
turf.visible_message("<span class='boldwarning'>The medbeams cross and EXPLODE!</span>")
turf.visible_message("<span class='userdanger'>The medbeams cross and EXPLODE!</span>")
explosion(B.loc,0,3,5,8)
qdel(dummy)
return 0