mirror of
https://gitlab.com/MaddoScientisto/cirnogodot.git
synced 2026-06-01 09:35:34 +00:00
Interface default functions
This commit is contained in:
parent
7566b0891c
commit
5e357e1a96
4 changed files with 75 additions and 25 deletions
|
|
@ -2,6 +2,7 @@
|
|||
using System.Linq;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
using Cirno._3D.TrenchBroom.EntityScripts.Triggers;
|
||||
using Cirno.Scripts.Components.FSM;
|
||||
using Cirno.Scripts.Components.FSM._3DPlayer;
|
||||
using Godot;
|
||||
|
|
@ -11,7 +12,7 @@ using GTweensGodot.Extensions;
|
|||
namespace Cirno.Scripts.Activables._3D;
|
||||
|
||||
[Tool]
|
||||
public partial class Teleporter3D : StaticBody3D, IActivable
|
||||
public partial class Teleporter3D : StaticBody3D, IActivable, ITargetable
|
||||
{
|
||||
[Export] public bool IsEnabled { get; set; }
|
||||
|
||||
|
|
@ -34,12 +35,12 @@ public partial class Teleporter3D : StaticBody3D, IActivable
|
|||
|
||||
[Export] public StringName DefaultAnimationName { get; private set; } = "Default";
|
||||
|
||||
public void _func_godot_apply_properties(Dictionary<string, string> props)
|
||||
public void _func_godot_apply_properties(Dictionary<string, Variant> props)
|
||||
{
|
||||
TargetGroup = props["target"];
|
||||
TargetGroup = props["target"].AsString();
|
||||
|
||||
TargetName = props["targetname"];
|
||||
IsEnabled = bool.Parse(props["enabled"]);
|
||||
TargetName = props["targetname"].AsString();
|
||||
IsEnabled = props["enabled"].AsBool();
|
||||
}
|
||||
|
||||
private void PlayAnimation(StringName name)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue