summaryrefslogtreecommitdiff
path: root/scripts/actors/Inspector.cs
diff options
context:
space:
mode:
authorMatheus <matheus.guedes.mg.m@gmail.com>2025-09-04 16:18:17 -0300
committerMatheus <matheus.guedes.mg.m@gmail.com>2025-09-04 16:18:17 -0300
commit9953c9a5818baa392a48a4d18339c73f3b7a814e (patch)
tree3484fbca78bfa217d84226cc774119fe054f6df9 /scripts/actors/Inspector.cs
parent7dbe2bbe431f77deb3515e5cf0810cfa07215d59 (diff)
Prepare
Diffstat (limited to 'scripts/actors/Inspector.cs')
-rw-r--r--scripts/actors/Inspector.cs40
1 files changed, 0 insertions, 40 deletions
diff --git a/scripts/actors/Inspector.cs b/scripts/actors/Inspector.cs
deleted file mode 100644
index e340543..0000000
--- a/scripts/actors/Inspector.cs
+++ /dev/null
@@ -1,40 +0,0 @@
-using Godot;
-
-/// <summary>
-/// Isto é uma abominação
-/// </summary>
-public partial class Inspector : Sprite2D
-{
- private Vector2I gridPosition = Vector2I.Zero;
- /// <summary>
- /// Posição do inspetor no espaço. Diferentemente de Position, GridPosition tem como formato
- /// os tiles do mapa.
- /// </summary>
- public Vector2I GridPosition {
- set {
- gridPosition = value;
- // O sistema de coordenadas do Godot é em pixels, mas faz mais sentido para o jogo utilizar coordenadas em tiles.
- // Esta propriedade converte um sistema para o outro automaticamente.
- Position = Grid.GridToWorld(value);
- }
- get => gridPosition;
- }
-
- public override void _Ready() {
- base._Ready();
- Camera2D camera = GetNode<Camera2D>("Camera2D");
- camera.Enabled = true;
- camera.MakeCurrent();
-
- SignalBus.Instance.EmitSignal(SignalBus.SignalName.InspectorMoved, GridPosition);
- }
-
- /// <summary>
- /// O Inspetor não faz parte do mapa.
- /// </summary>
- /// <param name="offset"></param>
- public void Walk(Vector2I offset) {
- GridPosition += offset;
- SignalBus.Instance.EmitSignal(SignalBus.SignalName.InspectorMoved, GridPosition);
- }
-} \ No newline at end of file