Complete reorga

This commit is contained in:
2026-03-09 17:55:23 +01:00
parent d9326e48cc
commit 10faf74405
703 changed files with 13040 additions and 1533 deletions
@@ -0,0 +1,54 @@
using System.Collections.Generic;
using UnityEngine;
using OctoCore.Localization;
using Unheimlich.Features.DetectiveBoard.Data;
namespace Unheimlich.Features.Dialogue.Data
{
[CreateAssetMenu(fileName = "NewDialogueNode", menuName = "Unheimlich/Dialogue/Dialogue Node")]
public class DialogueNode : ScriptableObject
{
[Header("Content")]
[Tooltip("Localized text displayed for this dialogue node")]
public OctoLocalizedTextData DialogueText;
[Header("Choices")]
[Tooltip("List of available choices for this dialogue. If empty, this is an end node")]
public List<DialogueChoiceData> Choices = new List<DialogueChoiceData>();
[Header("End Node Settings")]
[Tooltip("For end nodes (no choices), delay in seconds before automatic close. 0 = requires player interaction to close")]
public float AutoCloseDelay = 3f;
[Header("Detective Board Integration")]
[Tooltip("Clue to unlock when this node is reached. Useful for end nodes to unlock evidence after a conversation")]
public ClueData ClueToUnlock;
public string GetLocalizedDialogueText()
{
if (DialogueText != null)
return OctoLocalization.GetLocalizedText(DialogueText);
return string.Empty;
}
public bool IsEndNode()
{
return Choices == null || Choices.Count == 0;
}
public bool HasValidChoices()
{
if (Choices == null || Choices.Count == 0)
return false;
foreach (var choice in Choices)
{
if (choice != null && choice.NextNode != null)
return true;
}
return false;
}
}
}