From 06238907a95b8a040deb80bbb52e754ebf43210c Mon Sep 17 00:00:00 2001 From: MrZ_26 <1046101471@qq.com> Date: Fri, 1 Nov 2024 00:47:30 +0800 Subject: [PATCH] =?UTF-8?q?exterior=E7=95=8C=E9=9D=A2=E5=A2=9E=E5=8A=A0?= =?UTF-8?q?=E8=AF=AD=E8=A8=80=E6=AF=94=E5=AF=B9=E5=8A=9F=E8=83=BD=EF=BC=88?= =?UTF-8?q?=E6=8C=89=E4=BD=8Fctrl=E5=86=8D=E5=88=87=E6=8D=A2=E8=AF=AD?= =?UTF-8?q?=E8=A8=80=EF=BC=89=20=E6=A1=86=E6=9E=B6=E8=B7=9F=E8=BF=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Zenitha | 2 +- assets/scene/lang_out.lua | 22 +++++++++++++++++++++- 2 files changed, 22 insertions(+), 2 deletions(-) diff --git a/Zenitha b/Zenitha index adfb57ad..8fc3e87e 160000 --- a/Zenitha +++ b/Zenitha @@ -1 +1 @@ -Subproject commit adfb57adb4ae09da8a41d87eff7188996c7f314a +Subproject commit 8fc3e87eedc959679c6cec83f8fcafd98573f861 diff --git a/assets/scene/lang_out.lua b/assets/scene/lang_out.lua index 48338f6c..6ce99be8 100644 --- a/assets/scene/lang_out.lua +++ b/assets/scene/lang_out.lua @@ -225,7 +225,27 @@ local function _setLang(lid) duration=1.26, } if SETTINGS.system.locale~=lid then - SETTINGS.system.locale=lid + if isCtrlPressed() then + local oldText=TABLE.copyAll(Text) + local oldLocale=SETTINGS.system.locale:upper() + SETTINGS.system.locale=lid + local newText=TABLE.copyAll(Text) + local newLocale=SETTINGS.system.locale:upper() + TABLE.flatten(oldText,6.26) + TABLE.flatten(newText,6.26) + for entry in next,newText do + if not oldText[entry] then + MSG.new('warn',("[$1] Missing '$2'"):repD(oldLocale,entry),26) + end + end + for entry in next,oldText do + if not newText[entry] then + MSG.new('warn',("[$1] Missing '$2'"):repD(newLocale,entry),26) + end + end + else + SETTINGS.system.locale=lid + end changed=true WIDGET._reset() end