mirror of
https://github.com/correl/mage.git
synced 2024-12-25 03:00:15 +00:00
Remove unneeded parameter from StackObjectCopyApplier.getNextNewTargetType (all users were using an Iterator or a fixed return value)
This commit is contained in:
parent
c401b35b63
commit
efa7b485b0
10 changed files with 10 additions and 10 deletions
|
@ -205,7 +205,7 @@ class BeamsplitterMageApplier implements StackObjectCopyApplier {
|
|||
}
|
||||
|
||||
@Override
|
||||
public MageObjectReferencePredicate getNextNewTargetType(int copyNumber) {
|
||||
public MageObjectReferencePredicate getNextNewTargetType() {
|
||||
return morPredicate;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -142,7 +142,7 @@ class ChefsKissApplier implements StackObjectCopyApplier {
|
|||
}
|
||||
|
||||
@Override
|
||||
public MageObjectReferencePredicate getNextNewTargetType(int copyNumber) {
|
||||
public MageObjectReferencePredicate getNextNewTargetType() {
|
||||
if (predicate.hasNext()) {
|
||||
return predicate.next();
|
||||
}
|
||||
|
|
|
@ -113,7 +113,7 @@ enum DonalHeraldOfWingsApplier implements StackObjectCopyApplier {
|
|||
}
|
||||
|
||||
@Override
|
||||
public MageObjectReferencePredicate getNextNewTargetType(int copyNumber) {
|
||||
public MageObjectReferencePredicate getNextNewTargetType() {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -87,7 +87,7 @@ enum DoubleMajorApplier implements StackObjectCopyApplier {
|
|||
}
|
||||
|
||||
@Override
|
||||
public MageObjectReferencePredicate getNextNewTargetType(int copyNumber) {
|
||||
public MageObjectReferencePredicate getNextNewTargetType() {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -80,7 +80,7 @@ enum ForkApplier implements StackObjectCopyApplier {
|
|||
}
|
||||
|
||||
@Override
|
||||
public MageObjectReferencePredicate getNextNewTargetType(int copyNumber) {
|
||||
public MageObjectReferencePredicate getNextNewTargetType() {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -108,7 +108,7 @@ class IvyGleefulSpellthiefEffect extends OneShotEffect {
|
|||
}
|
||||
|
||||
@Override
|
||||
public MageObjectReferencePredicate getNextNewTargetType(int copyNumber) {
|
||||
public MageObjectReferencePredicate getNextNewTargetType() {
|
||||
return morPredicate;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -174,7 +174,7 @@ class ObNixilisTheAdversaryApplier implements StackObjectCopyApplier {
|
|||
}
|
||||
|
||||
@Override
|
||||
public MageObjectReferencePredicate getNextNewTargetType(int copyNumber) {
|
||||
public MageObjectReferencePredicate getNextNewTargetType() {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -30,7 +30,7 @@ public abstract class CopySpellForEachItCouldTargetEffect extends OneShotEffect
|
|||
}
|
||||
|
||||
@Override
|
||||
public MageObjectReferencePredicate getNextNewTargetType(int copyNumber) {
|
||||
public MageObjectReferencePredicate getNextNewTargetType() {
|
||||
if (newTargetTypes.hasNext()) {
|
||||
return newTargetTypes.next();
|
||||
}
|
||||
|
|
|
@ -88,7 +88,7 @@ public abstract class StackObjectImpl implements StackObject {
|
|||
|
||||
newTargetTypes = new HashMap<>();
|
||||
for (int i = 0; i < amount; i++) {
|
||||
MageObjectReferencePredicate newTargetType = applier.getNextNewTargetType(i + 1);
|
||||
MageObjectReferencePredicate newTargetType = applier.getNextNewTargetType();
|
||||
if (newTargetType == null) {
|
||||
currentAnyTargetNumber++;
|
||||
String message = "Any target";
|
||||
|
|
|
@ -20,5 +20,5 @@ public interface StackObjectCopyApplier extends Serializable {
|
|||
* @param copyNumber current number of copy, starts with 1
|
||||
* @return
|
||||
*/
|
||||
MageObjectReferencePredicate getNextNewTargetType(int copyNumber);
|
||||
MageObjectReferencePredicate getNextNewTargetType();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue