mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-23 13:05:44 +01:00
Fluff Paper Language Setting (#18850)
Fluff papers can now have a written language set, as the code for translating things was copypasted in like 6 places.
This commit is contained in:
@@ -765,6 +765,19 @@
|
||||
/obj/item/paper/fluff
|
||||
name = "fluff paper"
|
||||
desc = "You aren't supposed to see this."
|
||||
///The language to translate the paper into. Set to the name of the language.
|
||||
var/language
|
||||
|
||||
/obj/item/paper/fluff/Initialize()
|
||||
. = ..()
|
||||
if(language)
|
||||
var/datum/language/L = GLOB.all_languages[language]
|
||||
if(istype(L) && L.written_style) //Don't want to try and write in Hivenet or something
|
||||
var/key = L.key
|
||||
var/languagetext = "\[lang=[key]]"
|
||||
languagetext += "[info]\[/lang]"
|
||||
info = parsepencode(languagetext)
|
||||
update_icon()
|
||||
|
||||
// Used in the deck 3 cafe on the SCCV Horizon.
|
||||
/obj/item/paper/fluff/microwave
|
||||
|
||||
Reference in New Issue
Block a user