Strip escaped newlines from edtext dialogues
This commit is contained in:
parent
96f1c43ac1
commit
7fc5346bae
|
|
@ -25,7 +25,12 @@ module EdText
|
||||||
sleep 0.2
|
sleep 0.2
|
||||||
end
|
end
|
||||||
result = nil
|
result = nil
|
||||||
|
# so here, we strip unescaped newlines from the untranslated text
|
||||||
|
# for the translator to find the right string. Then from the
|
||||||
|
# translated text, we replace escaped newlines with empty strings.
|
||||||
|
# yeah.
|
||||||
text = Language.tr(text.to_s.gsub(/\s*\n\s*/, " ").strip)
|
text = Language.tr(text.to_s.gsub(/\s*\n\s*/, " ").strip)
|
||||||
|
.to_s.gsub(/\s*\\n\s*/, "").strip
|
||||||
thread = Thread.new do
|
thread = Thread.new do
|
||||||
result = Oneshot.msgbox(type, text
|
result = Oneshot.msgbox(type, text
|
||||||
.gsub("\\p", $game_oneshot.player_name) +
|
.gsub("\\p", $game_oneshot.player_name) +
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue