mirror of
https://gitlab.com/MaddoScientisto/cirnogodot.git
synced 2026-06-10 08:05:54 +00:00
Directional computers
This commit is contained in:
parent
72ce9fb932
commit
7ec45b56b1
13 changed files with 164 additions and 46 deletions
|
|
@ -1,11 +1,13 @@
|
|||
using Godot;
|
||||
using System;
|
||||
using System.Threading.Tasks;
|
||||
using Cirno.Scripts.Components;
|
||||
using Cirno.Scripts.Enums;
|
||||
|
||||
public partial class Chair : StaticBody2D
|
||||
public partial class Chair : StaticBody2D, IIRotateable
|
||||
{
|
||||
[Export]
|
||||
public ChairDirection Direction { get; private set; } = ChairDirection.Down;
|
||||
public Direction Direction { get; set; } = Direction.Down;
|
||||
|
||||
private AnimatedSprite2D _animatedSprite;
|
||||
|
||||
|
|
@ -20,7 +22,7 @@ public partial class Chair : StaticBody2D
|
|||
{
|
||||
_animatedSprite = GetNode<AnimatedSprite2D>("AnimatedSprite2D");
|
||||
|
||||
_animatedSprite.Play(Direction.ToString());
|
||||
//_animatedSprite.Play(Direction.ToString());
|
||||
}
|
||||
|
||||
public override void _Process(double delta)
|
||||
|
|
@ -44,13 +46,5 @@ public partial class Chair : StaticBody2D
|
|||
_timer = 0;
|
||||
}
|
||||
|
||||
|
||||
public enum ChairDirection
|
||||
{
|
||||
Up,
|
||||
Down,
|
||||
Left,
|
||||
Right,
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue