add : credits screen

This commit is contained in:
Ferlat Thibaud
2026-06-12 17:55:30 +02:00
parent 6c22a6bd2e
commit 882230fba4
6 changed files with 21179 additions and 21 deletions
@@ -3,6 +3,7 @@ using OctoCore.Navigation.Data;
using OctoCore.UI;
using UnityEngine;
using UnityEngine.EventSystems;
using UnityEngine.InputSystem;
using UnityEngine.UI;
namespace OctoCore.Navigation
@@ -104,18 +105,28 @@ namespace OctoCore.Navigation
}
}
// --- Add your custom button methods below ---
public void SelectMainDefaultButton()
{
StartCoroutine(SelectAfterFrame(_mainPanelDefaultButton));
}
public void SelectDebugFirstButton()
{
EventSystem.current.SetSelectedGameObject(_optionalPanelFirstButton.gameObject);
StartCoroutine(SelectAfterFrame(_optionalPanelFirstButton));
}
public void SelectMainDefaultButton()
private IEnumerator SelectAfterFrame(Button button)
{
EventSystem.current.SetSelectedGameObject(_mainPanelDefaultButton.gameObject);
MultiTargetButton.ClearPersistence();
EventSystem.current.SetSelectedGameObject(button.gameObject);
// Ignore mouse hover for 0.1s so it doesn't steal selection
OctoMainMenu.IgnoreMouseUntil = Time.time + 0.1f;
yield break;
}
// Exposed so MultiTargetButton can check before activating on hover
public static float IgnoreMouseUntil = 0f;
public void ClearButtonPersistence()
{
MultiTargetButton.ClearPersistence();