mirror of
https://gitlab.com/MaddoScientisto/cirnogodot.git
synced 2026-06-01 11:15:33 +00:00
Rebel Base map
This commit is contained in:
parent
dd979fe50a
commit
f28a3b70fd
14 changed files with 1136 additions and 5 deletions
|
|
@ -9,12 +9,18 @@ namespace Cirno.Scripts.Activables;
|
|||
[Tool]
|
||||
public partial class Terminal3D : Area3D, IInteractable
|
||||
{
|
||||
[Export] public StringName TimelineName = "timeline";
|
||||
[Export] public StringName TimelineName = "";
|
||||
private DialogueTools _dialogueInstance;
|
||||
|
||||
public override void _Ready()
|
||||
{
|
||||
if (Engine.IsEditorHint()) return;
|
||||
if (string.IsNullOrWhiteSpace(TimelineName))
|
||||
{
|
||||
this.RemoveFromGroup("Interactable");
|
||||
|
||||
return;
|
||||
}
|
||||
_dialogueInstance = new DialogueTools();
|
||||
_dialogueInstance.Init(this, TimelineName);
|
||||
}
|
||||
|
|
@ -27,6 +33,7 @@ public partial class Terminal3D : Area3D, IInteractable
|
|||
public bool Activate(ActivationType activationType = ActivationType.Toggle)
|
||||
{
|
||||
if (Engine.IsEditorHint()) return false;
|
||||
if (string.IsNullOrWhiteSpace(TimelineName)) return false;
|
||||
_dialogueInstance.Start(this);
|
||||
|
||||
return true;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue