2025-08-11 14:04:06 -04:00
|
|
|
using Ichni.Menu;
|
|
|
|
|
using UnityEngine;
|
|
|
|
|
|
|
|
|
|
namespace Ichni.UI
|
|
|
|
|
{
|
|
|
|
|
public class GamePlaySettingsWindow : SettingsWindow
|
|
|
|
|
{
|
|
|
|
|
public TextButton offsetEditorButton;
|
2025-08-22 14:54:40 -04:00
|
|
|
public Dropdown languageDropdown;
|
2025-08-11 14:04:06 -04:00
|
|
|
public override void Initialize()
|
|
|
|
|
{
|
2026-07-25 13:27:53 -04:00
|
|
|
offsetEditorButton.SetUp();
|
2025-08-11 14:04:06 -04:00
|
|
|
offsetEditorButton.updateValueAction = () =>
|
|
|
|
|
{
|
|
|
|
|
gameObject.SetActive(false);
|
|
|
|
|
MenuManager.instance.settingsUIPage.offsetEditor.gameObject.SetActive(true);
|
|
|
|
|
MenuManager.instance.settingsUIPage.offsetEditor.offsetEditingContainer.SetActive(true);
|
|
|
|
|
MenuManager.instance.settingsUIPage.offsetEditor.Play();
|
2025-08-27 21:45:18 -04:00
|
|
|
MenuManager.instance.settingsUIPage.settingsWindowController.buttonsContainer.gameObject.SetActive(false);
|
2025-08-11 14:04:06 -04:00
|
|
|
};
|
2025-08-22 14:54:40 -04:00
|
|
|
|
2026-07-25 13:27:53 -04:00
|
|
|
// 语言列表采用各语言的自称(例如日本語、한국어),不应随当前 Locale 再次翻译。
|
|
|
|
|
languageDropdown.SetUpRuntime(
|
|
|
|
|
SettingsManager.instance.GetLanguageDropdownIndex(),
|
|
|
|
|
MenuManager.instance.displayLanguageList);
|
2025-08-22 14:54:40 -04:00
|
|
|
languageDropdown.updateValueAction = () =>
|
|
|
|
|
{
|
2026-07-24 17:56:30 -04:00
|
|
|
SettingsManager.instance.SetLanguageByDropdownIndex(languageDropdown.selectedIndex);
|
2025-08-22 14:54:40 -04:00
|
|
|
};
|
2025-08-11 14:04:06 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public override void SetValuesFromSettings()
|
|
|
|
|
{
|
2026-07-24 17:56:30 -04:00
|
|
|
languageDropdown.SetValue(SettingsManager.instance.GetLanguageDropdownIndex());
|
2025-08-11 14:04:06 -04:00
|
|
|
}
|
|
|
|
|
}
|
2026-07-19 16:44:58 -04:00
|
|
|
}
|