* AI PLayer - Fixed a problem with targets of Venser, Shaper Savant.

This commit is contained in:
LevelX2 2015-01-31 10:00:16 +01:00
parent 44f3ac8117
commit 19d71aaf84
2 changed files with 15 additions and 9 deletions

View file

@ -91,6 +91,10 @@ public class TargetSpellOrPermanent extends TargetImpl {
return this.filter;
}
public FilterPermanent getPermanentFilter() {
return this.filterPermanent;
}
public void setFilter(FilterSpellOrPermanent filter) {
this.filter = filter;
}
@ -197,7 +201,7 @@ public class TargetSpellOrPermanent extends TargetImpl {
@Override
public Set<UUID> possibleTargets(UUID sourceId, UUID sourceControllerId, Game game) {
Set<UUID> possibleTargets = new HashSet<UUID>();
Set<UUID> possibleTargets = new HashSet<>();
MageObject targetSource = game.getObject(sourceId);
for (StackObject stackObject: game.getStack()) {
Spell spell = game.getStack().getSpell(stackObject.getId());
@ -215,7 +219,7 @@ public class TargetSpellOrPermanent extends TargetImpl {
@Override
public Set<UUID> possibleTargets(UUID sourceControllerId, Game game) {
Set<UUID> possibleTargets = new HashSet<UUID>();
Set<UUID> possibleTargets = new HashSet<>();
for (StackObject stackObject: game.getStack()) {
Spell spell = game.getStack().getSpell(stackObject.getId());
if (spell != null && filter.match(spell, null, sourceControllerId, game) && filter.match(spell, game)) {