diff options
Diffstat (limited to 'go/game/map.go')
| -rw-r--r-- | go/game/map.go | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/go/game/map.go b/go/game/map.go index 2b0bebd7..be541cdd 100644 --- a/go/game/map.go +++ b/go/game/map.go @@ -285,6 +285,12 @@ func (m *Map) FreeTiles() []*Tile { return m.FilterTiles(func(t *Tile) bool { return t.IsFree() }) } +func (m *Map) AvailableTilesFor(c *Card) []*Tile { + return m.FilterTiles(func(t *Tile) bool { + return t.IsAvailableForCard(c) + }) +} + func (m *Map) distributeStoreCards(cards PileOfCards, rand *rand.Rand) { nStores := len(m.Stores) stores := make([]*Store, 0, nStores) |
