* Added Animate Dead (not finished yet).

This commit is contained in:
LevelX2 2014-11-05 18:04:56 +01:00
parent 8412515be0
commit 169835dbea
10 changed files with 550 additions and 10 deletions

View file

@ -35,7 +35,6 @@ import mage.constants.Zone;
import mage.abilities.keyword.ProtectionAbility;
import mage.abilities.mana.ManaAbility;
import mage.game.Game;
import mage.players.Player;
/**
* Represents a collection of {@link Ability Abilities}. This is the top most

View file

@ -45,12 +45,13 @@ public class LoseAbilitySourceEffect extends ContinuousEffectImpl{
@Override
public boolean apply(Game game, Ability source){
Permanent permanent = game.getPermanent(source.getSourceId());
if(permanent != null){
while(permanent.getAbilities().contains(ability)){
if (!permanent.getAbilities().remove(ability)) {
logger.warn("ability" + ability.getRule() + "couldn't be removed.");
}
}
if (permanent != null){
permanent.getAbilities().remove(ability);
// while(permanent.getAbilities().contains(ability)){
// if (!permanent.getAbilities().remove(ability)) {
// logger.warn("ability " + ability.getRule() + " couldn't be removed.");
// }
// }
}
return true;
}