chore: Project Restructuring & Theatre

This commit is contained in:
Alexandre Coirier
2026-05-13 12:24:48 +02:00
parent 4070916c1f
commit e96d0bf6e6
2145 changed files with 20957 additions and 44792 deletions
@@ -0,0 +1,49 @@
#if UNITY_EDITOR || DEVELOPMENT_BUILD
using UnityEngine;
using UnityEngine.InputSystem;
using Unheimlich.Features.Diapason;
namespace Unheimlich.Dev
{
public class DiapasonEquipmentTester : MonoBehaviour
{
[Header("References")]
[SerializeField] private DiapasonEquipmentManager _equipmentManager;
[Header("Input")]
[SerializeField] private Key _equipKey = Key.E;
[SerializeField] private Key _unequipKey = Key.R;
void Update()
{
if (_equipmentManager == null)
return;
if (Keyboard.current[_equipKey].wasPressedThisFrame)
{
_equipmentManager.EquipDiapason();
}
if (Keyboard.current[_unequipKey].wasPressedThisFrame)
{
_equipmentManager.UnequipDiapason();
}
}
void OnGUI()
{
GUILayout.BeginArea(new Rect(10, 10, 350, 150));
GUILayout.Label("=== Diapason Equipment System ===");
GUILayout.Label($"Press {_equipKey} to Equip Diapason");
GUILayout.Label($"Press {_unequipKey} to Unequip Diapason");
GUILayout.Label("");
GUILayout.Label("When equipped:");
GUILayout.Label("• Move LEFT hand to touch AudioListenable");
GUILayout.Label("• LEFT CLICK to tap and activate");
GUILayout.EndArea();
}
}
}
#endif
@@ -0,0 +1,2 @@
fileFormatVersion: 2
guid: 9279e0fb73118d14ba6f2cf05170a660
@@ -0,0 +1,67 @@
#if UNITY_EDITOR || DEVELOPMENT_BUILD
using UnityEngine;
using OctoCore.Localization;
using UnityEngine.InputSystem;
namespace Unheimlich.Dev
{
/// <summary>
/// Simple debug script to switch language at runtime.
/// Attach to any GameObject and press keys to change language.
/// </summary>
public class LanguageSwitcher : MonoBehaviour
{
[Header("Info")]
[Tooltip("Current language")]
[SerializeField] private OctoLanguages _currentLanguage;
void Start()
{
if (OctoCore.OctoCore.Instance != null && OctoCore.OctoCore.Instance.Localization != null)
{
_currentLanguage = OctoCore.OctoCore.Instance.Localization.WrittenLanguage;
UnityEngine.Debug.Log($"[LanguageSwitcher] Current language: {_currentLanguage}");
UnityEngine.Debug.Log($"[LanguageSwitcher] Press F1 for English, F2 for French");
}
}
void Update()
{
if (OctoCore.OctoCore.Instance == null || OctoCore.OctoCore.Instance.Localization == null)
return;
if (Keyboard.current == null)
return;
if (Keyboard.current.f1Key.wasPressedThisFrame)
{
SetLanguage(OctoLanguages.English);
}
else if (Keyboard.current.f2Key.wasPressedThisFrame)
{
SetLanguage(OctoLanguages.French);
}
}
private void SetLanguage(OctoLanguages language)
{
OctoCore.OctoCore.Instance.Localization.SetLanguageWritten(language);
_currentLanguage = language;
UnityEngine.Debug.Log($"<color=green>[LanguageSwitcher]</color> Language changed to: <color=yellow>{language}</color>");
}
void OnGUI()
{
// Display current language in top-left corner
if (OctoCore.OctoCore.Instance != null && OctoCore.OctoCore.Instance.Localization != null)
{
GUI.color = Color.yellow;
GUI.Label(new Rect(10, 10, 300, 30), $"Language: {_currentLanguage}");
GUI.Label(new Rect(10, 30, 300, 30), $"[F1] EN | [F2] FR");
GUI.color = Color.white;
}
}
}
}
#endif
@@ -0,0 +1,2 @@
fileFormatVersion: 2
guid: 86180434dad93e344b4a5229575d4757