import java.util.*; public class KillCity3 extends Necromancy { String spellName = "Pestilence"; int manaCost = 20; int level = 3; String description = "You start a disastrous epidemic in a city."; String[] targets = {"city"}; String target; public void cast(Fod game, int playerNr, String arg) { System.out.println("-->Player "+playerNr+" casts "+spellName+" on "+arg); Object o = game.cities.get(arg); if(o!=null){ City c = (City)o; if (c.Development<50 && !c.isHomeCity(game.players)) c.increasePopulation(-(15+Dice.rand(15))); } } ////Primitves public String getSpellName(){ return spellName; } public String getDescription(){ return description; } public int getManaCost(){ return manaCost; } public int getLevel(){ return level; } public String[] getTargetProfile(){ return targets; } public String getTarget(){ return target; } public String setTarget(String t){ target = t; return target; } }