mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-27 15:17:01 +01:00
Fix various issues with names in string interpolation (#89246)
## About The Pull Request Commit messages should be descriptive of all changes. The "incorrect `\The` macro capitalization" was intentional when it was added, but as far as I know TG says "the supermatter" rather than "The Supermatter," so it's incorrect now. This is completely untested. I don't even know how you'd go about testing this, it's just a fuckton of strings. Someday I want to extract them and run NLP on it to catch grammar problems... ## Why It's Good For The Game Basic grammar pass for name strings. Should make `\the` work better and avoid cases like `the John Smith`.
This commit is contained in:
@@ -50,7 +50,7 @@
|
||||
so quickly that it generally doesn't matter. You're remarkably resilient to any damage besides this and it's hard for you to really die at all. You should go around and bring happiness and \
|
||||
free cake to the station!</b>")
|
||||
var/default_name = initial(name)
|
||||
var/new_name = sanitize_name(reject_bad_text(tgui_input_text(src, "You are the [name]. Would you like to change your name to something else?", "Name change", default_name, MAX_NAME_LEN)), cap_after_symbols = FALSE)
|
||||
var/new_name = sanitize_name(reject_bad_text(tgui_input_text(src, "You are \the [src]. Would you like to change your name to something else?", "Name change", default_name, MAX_NAME_LEN)), cap_after_symbols = FALSE)
|
||||
if(new_name)
|
||||
to_chat(src, span_notice("Your name is now <b>[new_name]</b>!"))
|
||||
name = new_name
|
||||
|
||||
@@ -109,7 +109,7 @@
|
||||
so quickly that it generally doesn't matter. You're remarkably resilient to any damage besides this and it's hard for you to really die at all. You should go around and bring happiness and \
|
||||
free bread to the station! 'I’m not alone, and you aren’t either'</b>")
|
||||
var/default_name = "Kobun"
|
||||
var/new_name = sanitize_name(reject_bad_text(tgui_input_text(src, "You are the [name]. Would you like to change your name to something else?", "Name change", default_name, MAX_NAME_LEN)), cap_after_symbols = FALSE)
|
||||
var/new_name = sanitize_name(reject_bad_text(tgui_input_text(src, "You are \the [src]. Would you like to change your name to something else?", "Name change", default_name, MAX_NAME_LEN)), cap_after_symbols = FALSE)
|
||||
if(new_name)
|
||||
to_chat(src, span_notice("Your name is now <b>[new_name]</b>!"))
|
||||
name = new_name
|
||||
|
||||
Reference in New Issue
Block a user