Aqua state
This commit is contained in:
parent
8708540770
commit
31ba172123
6 changed files with 48 additions and 36 deletions
|
|
@ -16,12 +16,13 @@ public partial class SnipachBehaviour : BaseBehaviour
|
|||
attackBox.Visible = dragging;
|
||||
}
|
||||
|
||||
public void OnDragEnd()
|
||||
public void OnDragEnd(bool aborted)
|
||||
{
|
||||
if (dragging == false) return;
|
||||
attackBox.Attack();
|
||||
dragging = false;
|
||||
attackBox.Visible = dragging;
|
||||
if (aborted) return;
|
||||
attackBox.Attack();
|
||||
timer.Start();
|
||||
}
|
||||
|
||||
|
|
@ -31,6 +32,14 @@ public partial class SnipachBehaviour : BaseBehaviour
|
|||
{
|
||||
attackBox.GlobalPosition = (Cursor.GetCursorPosition() / FieldParams.Tile).Ceil() * FieldParams.Tile - new Vector2(20, 14);
|
||||
}
|
||||
if (timer.TimeLeft > 0)
|
||||
{
|
||||
GetParent<Node2D>().Modulate = Colors.DeepSkyBlue;
|
||||
}
|
||||
else
|
||||
{
|
||||
GetParent<Node2D>().Modulate = Colors.White;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue