package org.academiadecodigo.bootcamp11.arabiannights.genies;

/**
 * MIT License
 * (c) 2017 Ricardo Constantino
 */

public class GrumpyGenie extends Genie {
    public GrumpyGenie(int maxWishes) {
        super(1, GenieType.GRUMPY);
    }

    @Override
    public void grantWish(String wish) {
        if (this.getWishesLeft() == this.getMaxWishes()) {
            grantOneWish(wish);
            System.out.println(this.getGenieType() + ": That wish was retarded. I'm going back to the lamp.\n");
        } else {
            System.out.println("\n(the genie went back into the lamp.)\n");
        }
    }
}
