diff --git a/isometric-park-fna/Components/BudgetLineComponent.cs b/isometric-park-fna/Components/BudgetLineComponent.cs --- a/isometric-park-fna/Components/BudgetLineComponent.cs +++ b/isometric-park-fna/Components/BudgetLineComponent.cs @@ -5,7 +5,6 @@ public struct BudgetLineComponent : IComponent { - public string category; public decimal amount; } diff --git a/isometric-park-fna/Engines/GameBridgeEngine.cs b/isometric-park-fna/Engines/GameBridgeEngine.cs --- a/isometric-park-fna/Engines/GameBridgeEngine.cs +++ b/isometric-park-fna/Engines/GameBridgeEngine.cs @@ -19,9 +19,10 @@ typeof(SetFontMessage), typeof(QuitGameMessage))] [Reads(typeof(AreaComponent), - typeof(ContractStatusComponent), - typeof(OptionsComponent), - typeof(PreserveComponent))] + typeof(PointComponent), + typeof(ContractStatusComponent), + typeof(OptionsComponent), + typeof(PreserveComponent))] class GameBridgeEngine : Engine { @@ -94,6 +95,7 @@ game.in_zone = false; game.in_active_zone = false; game.in_preserve = false; + game.has_tower = false; foreach (ref readonly var entity in ReadEntities()) { var areaComponent = GetComponent(entity); @@ -125,7 +127,16 @@ } } } + foreach (ref readonly var entity in ReadEntities()) + { + var point_component = GetComponent(entity); + if (game.mouseGrid == point_component.Square) + { + game.has_tower = true; + } + + } foreach (ref readonly var message in ReadMessages()) { diff --git a/isometric-park-fna/FNAGame.cs b/isometric-park-fna/FNAGame.cs --- a/isometric-park-fna/FNAGame.cs +++ b/isometric-park-fna/FNAGame.cs @@ -86,6 +86,7 @@ public bool in_zone; public bool in_active_zone; public bool in_preserve; + public bool has_tower; public bool isPlaying = false; @@ -881,6 +882,10 @@ treeType, useStatus); } + else if (this.has_tower) { + status_left = String.Format("{0:},{1:} Watch Tower ({2})", this.mouseGrid.X, this.mouseGrid.Y, + useStatus); + } else { status_left = String.Format("{0:},{1:} {2} ({3})", this.mouseGrid.X, this.mouseGrid.Y, treeStatusAdjective,