package controls; import resources.Algo; public class TurnPlayer extends AbstractGameState { public TurnPlayer(Algo algo) { super(algo); } @Override public void attack(int guess, int attacker, int target) { if (isDeckLess()) { algo.selectAndAttackA(attacker, target, guess); isSucceedLatestAttack = algo.getResultBySelectingA().getKey(); } else { algo.drawAndAttackA(target, guess); isSucceedLatestAttack = algo.getResultByDrawingA().getKey(); } } }