mirror of
https://gitlab.com/MaddoScientisto/cirnogodot.git
synced 2026-06-12 13:15:54 +00:00
Preliminary lasers
This commit is contained in:
parent
3a7fd66193
commit
7cb5bfb593
20 changed files with 1779 additions and 1049 deletions
|
|
@ -38,6 +38,11 @@ public partial class OpenCloseActorAnimationManager3D : Node
|
|||
}
|
||||
}
|
||||
|
||||
public void Toggle(bool state)
|
||||
{
|
||||
AnimationPlayer.Play(state ? OpeningAnimationName : ClosingAnimationName);
|
||||
}
|
||||
|
||||
public void PlayOpening()
|
||||
{
|
||||
AnimationPlayer.Play(OpeningAnimationName);
|
||||
|
|
|
|||
23
Scripts/Actors/3D/Turret3DAnimator.cs
Normal file
23
Scripts/Actors/3D/Turret3DAnimator.cs
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
using Godot;
|
||||
|
||||
namespace Cirno.Scripts.Actors._3D;
|
||||
|
||||
public partial class Turret3DAnimator : Node
|
||||
{
|
||||
[Export] public AnimationPlayer Animator { get; private set; }
|
||||
[Export] public StringName OnAnimationName { get; private set; }
|
||||
[Export] public StringName OffAnimationName { get; private set; }
|
||||
|
||||
public void ChangeState(bool state)
|
||||
{
|
||||
if (state)
|
||||
{
|
||||
Animator?.Play(OnAnimationName);
|
||||
}
|
||||
else
|
||||
{
|
||||
Animator?.Play(OffAnimationName);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
1
Scripts/Actors/3D/Turret3DAnimator.cs.uid
Normal file
1
Scripts/Actors/3D/Turret3DAnimator.cs.uid
Normal file
|
|
@ -0,0 +1 @@
|
|||
uid://cbnblvav5ck8a
|
||||
Loading…
Add table
Add a link
Reference in a new issue