Mark cards that are not playable

This commit is contained in:
henriquenakashima 2020-09-24 23:00:36 -04:00
parent aa78658949
commit 45b91ed352
9 changed files with 162 additions and 14 deletions

View file

@ -28,15 +28,18 @@ public class BattlePlayerControls : MonoBehaviour
public void Init(
BattleDeck<HeroCard> heroDeck, BattleDeck<MonsterCard> monsterDeck, PlayArea playArea,
InsightLevel insightLevel) {
InsightLevel insightLevel, HandPlayability<HeroCard> heroHandPlayability) {
this.heroDeck = heroDeck;
this.monsterDeck = monsterDeck;
this.playArea = playArea;
this.insightLevel = insightLevel;
this.heroHandControls = new HandControls<HeroCard>(this.uiCanvas, this.cardPrefab, HandControlsPosition.Bottom, int.MaxValue);
this.heroHandControls = new HandControls<HeroCard>(
this.uiCanvas, this.cardPrefab, HandControlsPosition.Bottom, TeamChoice.Heroes,
int.MaxValue, heroHandPlayability);
this.heroHandControls.OnCardClicked += OnHeroCardClicked;
this.monsterHandControls = new HandControls<MonsterCard>(this.uiCanvas, this.cardPrefab, HandControlsPosition.Top, 1);
this.monsterHandControls = new HandControls<MonsterCard>(
this.uiCanvas, this.cardPrefab, HandControlsPosition.Top, TeamChoice.Monsters, 1, null);
this.monsterHandControls.OnCardClicked += OnMonsterCardClicked;
this.cardsInPlayUIs = new Dictionary<BaseCard, GameObject>();