SupaLidlGame/Scenes/Map.cs

48 lines
775 B
C#
Raw Normal View History

2023-03-26 10:53:45 -07:00
using Godot;
using System;
2023-06-03 18:21:46 -07:00
namespace SupaLidlGame.Scenes;
public partial class Map : TileMap
2023-03-26 10:53:45 -07:00
{
2023-06-03 18:21:46 -07:00
[Export]
public Node2D Entities { get; set; }
2023-03-26 10:53:45 -07:00
2023-06-03 18:21:46 -07:00
[Export]
public Node2D Areas { get; set; }
2023-03-26 10:53:45 -07:00
2023-06-03 18:21:46 -07:00
[Export]
public Node2D Spawners { get; set; }
2023-03-26 10:53:45 -07:00
2023-06-03 18:21:46 -07:00
[Export]
public Vector2 CameraLowerBound { get; set; }
2023-03-26 10:53:45 -07:00
2023-06-03 18:21:46 -07:00
[Export]
public Vector2 CameraUpperBound { get; set; }
2023-03-26 10:53:45 -07:00
2023-06-03 18:21:46 -07:00
private bool _active;
2023-03-26 10:53:45 -07:00
2023-06-03 18:21:46 -07:00
public bool Active
{
get
2023-03-26 10:53:45 -07:00
{
2023-06-03 18:21:46 -07:00
return _active;
2023-03-26 10:53:45 -07:00
}
2023-06-03 18:21:46 -07:00
set
2023-03-26 10:53:45 -07:00
{
2023-06-03 18:21:46 -07:00
_active = Visible = value;
SetProcess(value);
2023-03-26 10:53:45 -07:00
}
2023-06-03 18:21:46 -07:00
}
2023-03-26 10:53:45 -07:00
2023-06-03 18:21:46 -07:00
public override void _Ready()
{
Active = true;
}
public override void _Process(double delta)
{
base._Process(delta);
2023-03-26 10:53:45 -07:00
}
}