Merge branch 'master' into subtypes

This commit is contained in:
LevelX2 2017-05-21 10:50:47 +02:00 committed by GitHub
commit 9e78410fff
12 changed files with 159 additions and 52 deletions

View file

@ -54,7 +54,7 @@ public class CastOnlyDuringPhaseStepSourceEffect extends ContinuousRuleModifying
return true;
}
}
return false; // casr not prevented by this effect
return false; // cast not prevented by this effect
}
@Override

View file

@ -58,7 +58,7 @@ public enum CardRepository {
// raise this if db structure was changed
private static final long CARD_DB_VERSION = 51;
// raise this if new cards were added to the server
private static final long CARD_CONTENT_VERSION = 80;
private static final long CARD_CONTENT_VERSION = 81;
private final TreeSet<String> landTypes = new TreeSet<>();
private Dao<CardInfo, Object> cardDao;
private Set<String> classNames;

View file

@ -48,6 +48,7 @@ public class ElspethSunsChampionEmblem extends Emblem {
public ElspethSunsChampionEmblem() {
this.setName("Emblem Elspeth");
this.setExpansionSetCodeForImage("THS");
Ability ability = new SimpleStaticAbility(Zone.COMMAND, new BoostControlledEffect(2, 2, Duration.EndOfGame, filter, false));
ability.addEffect(new GainAbilityControlledEffect(FlyingAbility.getInstance(), Duration.EndOfGame, filter));
this.getAbilities().add(ability);

View file

@ -73,7 +73,7 @@ public class TargetActivatedAbility extends TargetObject {
}
StackObject stackObject = game.getStack().getStackObject(id);
return stackObject != null && stackObject.getStackAbility() != null && stackObject.getStackAbility().getAbilityType() == AbilityType.ACTIVATED
&& filter.match(((ActivatedAbility) stackObject), game);
&& filter.match(((ActivatedAbility) stackObject.getStackAbility()), game);
}
@Override
@ -104,7 +104,7 @@ public class TargetActivatedAbility extends TargetObject {
for (StackObject stackObject : game.getStack()) {
if (stackObject.getStackAbility().getAbilityType() == AbilityType.ACTIVATED
&& game.getState().getPlayersInRange(sourceControllerId, game).contains(stackObject.getStackAbility().getControllerId())
&& filter.match(((ActivatedAbility) stackObject), game)) {
&& filter.match(((StackAbility) stackObject), game)) {
possibleTargets.add(stackObject.getStackAbility().getId());
}
}