PopTheLockClone/GameManager.cs
2025-06-05 03:06:26 -04:00

41 lines
709 B
C#

using Godot;
using System;
public partial class GameManager : Node
{
public enum State
{
IDLE,
PLAY,
LOSS,
WIN
}
public bool playing = false;
public static State CurrentState { get; private set; }
public override void _Ready()
{
CurrentState = State.IDLE;
}
public override void _Process(double delta)
{
if (Input.IsActionJustPressed("Press"))
{
playing = !playing;
if (playing)
{
CurrentState = State.PLAY;
}
else
{
//CurrentState = State.IDLE;
}
}
}
}