Newer
Older
Algolike / src / main / java / controls / TurnBot.java
package controls;

import resources.Algo;

public class TurnBot extends AbstractGameState{
    public TurnBot(Algo algo) {
        super(algo);
    }

    @Override
    public void attack(int guess, int attacker, int target) {
        if (isDeckLess()) {
            algo.inputSelectB(guess, attacker, target);
            isSucceedLatestAttack = algo.getSucceedSelectB().getKey();
        } else {
            algo.inputDrawB(guess, target);
            isSucceedLatestAttack = algo.getSucceedDrawB().getKey();
        }
    }
}