Package smack.down.ninjas

Source Code of smack.down.ninjas.WayOfDeception

package smack.down.ninjas;

import smack.down.Action;
import smack.down.Base;
import smack.down.Callback;
import smack.down.Faction;
import smack.down.Minion;

public class WayOfDeception extends Action {
 
  public WayOfDeception() {
    super("Way of Deception", Faction.Ninjas, Target.Minion);
  }
 
  public void play(final Minion minion, Callback callback) {
    Base base = callback.selectBaseInPlay("Select destination", true, new Callback.Predicate<Base>() {
      public boolean eval(Base arg) {
        return arg != minion.getBase();
      }
    });
   
    minion.getBase().removeMinion(minion);
    minion.setBase(base);
    base.addMinion(minion);
  }
}
TOP

Related Classes of smack.down.ninjas.WayOfDeception

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.