package cards.maumau.model;

public class WaitForMauState implements PlayerState {
    private final PlayerHandler handler;

    public WaitForMauState(PlayerHandler handler) {
        this.handler = handler;
    }

    @Override
    public void nextTurn(int n) {
        // Draw a card and proceed to next turn
        handler.getCurrentPlayer().drawCards(1);
        handler.localNextTurn(n);
        handler.setCurrentState(handler.getWaitForNextTurnState());
    }

    @Override
    public void mau(Player p) {
        if (p == handler.getRemember()) {
            handler.setCurrentState(handler.getWaitForMauMauState());
        }
    }

    @Override
    public void maumau(Player p) {
        // Do nothing or handle invalid state transition
    }
}
