2025-08-11 14:04:06 -04:00
|
|
|
using System.Collections;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using Ichni.Menu;
|
2025-08-22 14:54:40 -04:00
|
|
|
using MoreMountains.Tools;
|
2025-08-11 14:04:06 -04:00
|
|
|
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()
|
|
|
|
|
{
|
2025-08-27 21:45:18 -04:00
|
|
|
offsetEditorButton.SetUp("Menu UI/Settings_Offset_Editor", "", "Menu UI/Settings_Enter");
|
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
|
|
|
|
|
|
|
|
languageDropdown.SetUp(gameSettings.languageIndex, MenuManager.instance.displayLanguageList, "Menu UI/Settings_Language");
|
|
|
|
|
languageDropdown.updateValueAction = () =>
|
|
|
|
|
{
|
|
|
|
|
gameSettings.languageIndex = languageDropdown.selectedIndex;
|
|
|
|
|
gameSettings.ApplyLanguage();
|
|
|
|
|
};
|
2025-08-11 14:04:06 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public override void SetValuesFromSettings()
|
|
|
|
|
{
|
2025-08-22 14:54:40 -04:00
|
|
|
languageDropdown.SetValue(gameSettings.languageIndex);
|
2025-08-11 14:04:06 -04:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|