aboutsummaryrefslogtreecommitdiff
path: root/go/game/unit_test.go
diff options
context:
space:
mode:
authorFlorian Fischer <florian.fischer@muhq.space>2023-02-07 00:32:39 +0100
committerFlorian Fischer <florian.fischer@muhq.space>2023-02-07 00:32:39 +0100
commit6bd6936e1aae2fb8d2f5fc95d3c8dcdbe799242d (patch)
tree861f7a977c2cd3f015c65c14b5257013650ca71e /go/game/unit_test.go
parent7ebfd783e9b2fbc788dc54b57185f7f41b257f2a (diff)
downloadmuhqs-game-6bd6936e1aae2fb8d2f5fc95d3c8dcdbe799242d.tar.gz
muhqs-game-6bd6936e1aae2fb8d2f5fc95d3c8dcdbe799242d.zip
intermediate commit
adding area effects and hooks for permanents entering and leaving tiles
Diffstat (limited to 'go/game/unit_test.go')
-rw-r--r--go/game/unit_test.go6
1 files changed, 6 insertions, 0 deletions
diff --git a/go/game/unit_test.go b/go/game/unit_test.go
index 0f16176c..53b585d8 100644
--- a/go/game/unit_test.go
+++ b/go/game/unit_test.go
@@ -20,9 +20,15 @@ symbols:
s := NewState()
r := strings.NewReader(mapDef)
s.Map, _ = readMap(r)
+
f := NewUnit(NewCard("nautics/fisher"), s.Map.TileAt(Position{2, 2}), nil)
+ s.AddPermanent(f)
+
a := NewUnit(NewCard("base/archer"), s.Map.TileAt(Position{1, 1}), nil)
+ s.AddPermanent(a)
+
sword := newEquipmentFromPath("base/sword", s.Map.TileAt(Position{0, 1}), nil)
+ s.AddPermanent(sword)
a.move(s, f.Tile())
if len(f.Pile()) != 1 {