This commit is contained in:
Marco 2025-02-21 18:57:00 +01:00
commit b07a8fe60d
33 changed files with 594 additions and 58 deletions

View file

@ -4,6 +4,8 @@ namespace Cirno.Scripts;
public partial class AlarmManager : Node2D
{
public static AlarmManager Instance { get; private set; }
public bool IsAlarmOn { get; private set; } = false;
public Vector2 LastAlarmPosition { get; private set; } = new Vector2();
@ -14,6 +16,11 @@ public partial class AlarmManager : Node2D
[Signal]
public delegate void AlarmDisabledEventHandler();
public override void _Ready()
{
Instance = this;
}
public void SoundAlarm(Vector2 location)
{
if (IsAlarmOn) return;