Skip to content

Commit

Permalink
words replace fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Legendaxe committed Oct 21, 2023
1 parent 8c24b08 commit 5e47df4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions modular_ss220/clothing/code/mask.dm
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,13 @@
var/message = speech_args[SPEECH_MESSAGE]
if(message[1] != "*")
var/static/regex/words = new(@"(?<![a-zA-Zа-яёА-ЯЁ])[a-zA-Zа-яёА-ЯЁ]+?(?![a-zA-Zа-яёА-ЯЁ])", "g")
message = replacetext(message, words, TYPE_PROC_REF(/obj/item/clothing/mask/fakemoustache/chef, words_replace))
message = replacetext(message, words, GLOBAL_PROC_REF(italian_words_replace))

if(prob(5))
message += pick(" Равиоли, равиоли, подскажи мне формуоли!"," Мамма-мия!"," Мамма-мия! Какая острая фрикаделька!", " Ла ла ла ла ла фуникули+ фуникуля+!", "Вордс Реплаке!")
speech_args[SPEECH_MESSAGE] = trim(message)

/obj/item/clothing/mask/fakemoustache/chef/proc/words_replace(word)
/proc/italian_words_replace(word)
var/static/list/italian_words
if(!italian_words)
italian_words = strings("italian_replacement.json", "italian")
Expand Down

0 comments on commit 5e47df4

Please sign in to comment.