diff options
Diffstat (limited to 'server/lib/core/state/loot_deck_state.dart')
| -rw-r--r-- | server/lib/core/state/loot_deck_state.dart | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/server/lib/core/state/loot_deck_state.dart b/server/lib/core/state/loot_deck_state.dart index 31c6df7..ccd1003 100644 --- a/server/lib/core/state/loot_deck_state.dart +++ b/server/lib/core/state/loot_deck_state.dart @@ -566,6 +566,22 @@ class LootDeck { 'enhancements': _enhancements, '1418': _hasCard1418, '1419': _hasCard1419, + // Pool card ids only: pool cards are the same live instances that enter + // the draw/discard piles (and mutate with them), so their full JSON would + // leak those mutations into the static pool. The enhancement menu needs + // the ids plus the `enhancements` map (card id → level). + 'pools': { + 'coin': _coinPool.map((c) => c.id).toList(), + 'lumber': _lumberPool.map((c) => c.id).toList(), + 'hide': _hidePool.map((c) => c.id).toList(), + 'metal': _metalPool.map((c) => c.id).toList(), + 'corpsecap': _corpsecapPool.map((c) => c.id).toList(), + 'arrowvine': _arrowvinePool.map((c) => c.id).toList(), + 'flamefruit': _flamefruitPool.map((c) => c.id).toList(), + 'axenut': _axenutPool.map((c) => c.id).toList(), + 'rockroot': _rockrootPool.map((c) => c.id).toList(), + 'snowthistle': _snowthistlePool.map((c) => c.id).toList(), + }, }; @override |
