From a8e73a4c705f038e16301ca68c2738af6fb470bc Mon Sep 17 00:00:00 2001 From: Page Asgardius Date: Wed, 10 Apr 2024 18:04:28 -0700 Subject: [PATCH] locale test --- main.tscn | 2 +- project.godot | 4 ++++ text.csv | 3 +++ text.csv.import | 17 +++++++++++++++++ text.en.translation | Bin 0 -> 470 bytes text.es.translation | Bin 0 -> 493 bytes text.ja.translation | Bin 0 -> 513 bytes 7 files changed, 25 insertions(+), 1 deletion(-) create mode 100644 text.csv create mode 100644 text.csv.import create mode 100644 text.en.translation create mode 100644 text.es.translation create mode 100644 text.ja.translation diff --git a/main.tscn b/main.tscn index ae3c7c8..e1bef42 100644 --- a/main.tscn +++ b/main.tscn @@ -20,7 +20,7 @@ offset_top = 258.0 offset_right = 949.0 offset_bottom = 326.0 theme_override_font_sizes/font_size = 49 -text = "Press enter or B to continue" +text = "TEXT_CONTINUE" horizontal_alignment = 1 vertical_alignment = 1 diff --git a/project.godot b/project.godot index 3538ed5..c863d8c 100644 --- a/project.godot +++ b/project.godot @@ -61,6 +61,10 @@ schar={ ] } +[internationalization] + +locale/translations=PackedStringArray("res://text.en.translation", "res://text.es.translation", "res://text.ja.translation") + [physics] 2d/default_gravity_vector=Vector2(0, 0) diff --git a/text.csv b/text.csv new file mode 100644 index 0000000..88cec0f --- /dev/null +++ b/text.csv @@ -0,0 +1,3 @@ +,en,es,ja +TEXT_CONTINUE,Press enter or B to continue,Presiona Intro o B para continuar,Enter または B を押して続行します +KEY_PUSH,Push Me!,Aprétame!,押す diff --git a/text.csv.import b/text.csv.import new file mode 100644 index 0000000..d940376 --- /dev/null +++ b/text.csv.import @@ -0,0 +1,17 @@ +[remap] + +importer="csv_translation" +type="Translation" +uid="uid://dt1vbfhc5vuwh" + +[deps] + +files=["res://text.en.translation", "res://text.es.translation", "res://text.ja.translation"] + +source_file="res://text.csv" +dest_files=["res://text.en.translation", "res://text.es.translation", "res://text.ja.translation"] + +[params] + +compress=true +delimiter=0 diff --git a/text.en.translation b/text.en.translation new file mode 100644 index 0000000000000000000000000000000000000000..54ac9f73f50dd845e6ac13cb8ef2caa8308c041d GIT binary patch literal 470 zcma)(&q~BF5XQ&#KkFY51VO|ug5YWIf*1F^7^)XRDA_u+(KcP0^dcTT`3j!Acu~+d z@ELpnU#0p@w+kK={NTrAzDy=$5}t+wYBh)00rOxJoQ%E6%?)3kmD;*YdsA506U`#r zeLlRrU%j4Bz5m1|6m5Z$T~U=WM_Cc;Eb>L+??3_;6(IS%O1XCBw zRJ%0tdXzD(A{|xnHT%|(o18C=O(w@&T$-_mNi+lYK-1~4-~a8UQBql((}C1Ne-1>Z zCImnxC;Do&(5}S~zzUFlg1P7pHW1}`!qivyA4f<@_I7~u*ah35R=uZZb^BHyhmUG~ Uzf+T{TpA3yN6loUM~EN&2J<0f&b zRxV787@7m9NCJq9Qj7CTi;`30bMliDbK*<#>;?e+qHUEDMjs-=BSC#<7PLTl|U?8)CfDsJ3=