Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 32 additions & 0 deletions Modules/Game/Scripts/Game.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
using DungeonRoyale.Modules.GameManagers.Scripts;

namespace DungeonRoyale.Modules.Game.Scripts;

public partial class Game : Node2D
{
private static TilesManager _tilesManager => TilesManager.Instance!;

[Export] public int MapWidth { get; private set; }
[Export] public int MapHeight { get; private set; }

private bool MapIsLoading { get; set; } = true;

public override void _Ready()
{
_tilesManager.SetUpTiles(MapWidth, MapHeight);
}

public void OnMapScanned()
{
MapIsLoading = false;

// Do something with the scanned map
}

public void OnMapGenerated()
{
MapIsLoading = false;

// Do something with the generated map
}
}
1 change: 1 addition & 0 deletions Modules/Game/Scripts/Game.cs.uid
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
uid://doeo50prutum0
9 changes: 9 additions & 0 deletions Modules/Map/MapScanner.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
namespace DungeonRoyale.Modules.Map;

public partial class MapScanner : Node2D
{
public void Scan()
{
// Scan the map
}
}
1 change: 1 addition & 0 deletions Modules/Map/MapScanner.cs.uid
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
uid://di6j7dxqlb03e
Loading