diff --git a/Mage.Client/src/main/java/mage/client/util/TransformedImageCache.java b/Mage.Client/src/main/java/mage/client/util/TransformedImageCache.java index 53706a6d0c..a5bac22407 100644 --- a/Mage.Client/src/main/java/mage/client/util/TransformedImageCache.java +++ b/Mage.Client/src/main/java/mage/client/util/TransformedImageCache.java @@ -72,16 +72,19 @@ public final class TransformedImageCache { static { // TODO: can we use a single map? - IMAGE_CACHE = ImageCaches.register(SoftValuesLoadingCache.from( - key -> SoftValuesLoadingCache.from(image -> { - if (key.width != image.getWidth() || key.height != image.getHeight()) { - image = resizeImage(image, key.width, key.height); - } - if (key.angle != 0.0) { - image = rotateImage(image, key.angle); - } - return image; - }))); + IMAGE_CACHE = ImageCaches.register(SoftValuesLoadingCache.from(TransformedImageCache::createTransformedImageCache)); + } + + private static SoftValuesLoadingCache createTransformedImageCache(Key key) { + return SoftValuesLoadingCache.from(image -> { + if (key.width != image.getWidth() || key.height != image.getHeight()) { + image = resizeImage(image, key.width, key.height); + } + if (key.angle != 0.0) { + image = rotateImage(image, key.angle); + } + return image; + }); } private static BufferedImage rotateImage(BufferedImage image, double angle) { diff --git a/Mage.Server/pom.xml b/Mage.Server/pom.xml index 58d437c31e..f5d4a5c71e 100644 --- a/Mage.Server/pom.xml +++ b/Mage.Server/pom.xml @@ -329,41 +329,6 @@ mage-server - - - - - org.eclipse.m2e - lifecycle-mapping - 1.0.1 - - - - - - - org.jvnet.jaxb2.maven2 - - - maven-jaxb2-plugin - - - [0.7.4,) - - - generate - - - - - - - - - - - - diff --git a/Mage.Sets/src/mage/cards/f/FlashFoliage.java b/Mage.Sets/src/mage/cards/f/FlashFoliage.java index 2460dffc86..a2c013efba 100644 --- a/Mage.Sets/src/mage/cards/f/FlashFoliage.java +++ b/Mage.Sets/src/mage/cards/f/FlashFoliage.java @@ -18,7 +18,7 @@ import mage.game.permanent.Permanent; import mage.game.permanent.token.SaprolingToken; import mage.game.permanent.token.Token; import mage.players.Player; -import mage.target.common.FilterCreatureAttackingYou; +import mage.filter.common.FilterCreatureAttackingYou; import mage.target.common.TargetCreaturePermanent; /** diff --git a/Mage.Sets/src/mage/cards/g/GiantTrapDoorSpider.java b/Mage.Sets/src/mage/cards/g/GiantTrapDoorSpider.java index 3e25f1cff0..d885595e3f 100644 --- a/Mage.Sets/src/mage/cards/g/GiantTrapDoorSpider.java +++ b/Mage.Sets/src/mage/cards/g/GiantTrapDoorSpider.java @@ -17,7 +17,7 @@ import mage.constants.SubType; import mage.constants.Zone; import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.AbilityPredicate; -import mage.target.common.FilterCreatureAttackingYou; +import mage.filter.common.FilterCreatureAttackingYou; import mage.target.common.TargetCreaturePermanent; /** diff --git a/Mage.Sets/src/mage/cards/h/HuntingKavu.java b/Mage.Sets/src/mage/cards/h/HuntingKavu.java index 011ceed8fc..10d6a9e987 100644 --- a/Mage.Sets/src/mage/cards/h/HuntingKavu.java +++ b/Mage.Sets/src/mage/cards/h/HuntingKavu.java @@ -17,7 +17,7 @@ import mage.constants.SubType; import mage.constants.Zone; import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.AbilityPredicate; -import mage.target.common.FilterCreatureAttackingYou; +import mage.filter.common.FilterCreatureAttackingYou; import mage.target.common.TargetCreaturePermanent; /** diff --git a/Mage.Sets/src/mage/cards/i/IceFloe.java b/Mage.Sets/src/mage/cards/i/IceFloe.java index 030b3a9076..9b101c88f4 100644 --- a/Mage.Sets/src/mage/cards/i/IceFloe.java +++ b/Mage.Sets/src/mage/cards/i/IceFloe.java @@ -15,7 +15,7 @@ import mage.constants.CardType; import mage.constants.Zone; import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.AbilityPredicate; -import mage.target.common.FilterCreatureAttackingYou; +import mage.filter.common.FilterCreatureAttackingYou; import mage.target.common.TargetCreaturePermanent; /** diff --git a/Mage.Sets/src/mage/cards/s/SnowFortress.java b/Mage.Sets/src/mage/cards/s/SnowFortress.java index 01ec8530ea..5d1b580f92 100644 --- a/Mage.Sets/src/mage/cards/s/SnowFortress.java +++ b/Mage.Sets/src/mage/cards/s/SnowFortress.java @@ -18,7 +18,7 @@ import mage.constants.Duration; import mage.constants.Zone; import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.AbilityPredicate; -import mage.target.common.FilterCreatureAttackingYou; +import mage.filter.common.FilterCreatureAttackingYou; import mage.target.common.TargetCreaturePermanent; /** diff --git a/Mage.Sets/src/mage/cards/s/SoulSnare.java b/Mage.Sets/src/mage/cards/s/SoulSnare.java index 27b5e19b93..375944152d 100644 --- a/Mage.Sets/src/mage/cards/s/SoulSnare.java +++ b/Mage.Sets/src/mage/cards/s/SoulSnare.java @@ -11,7 +11,7 @@ import mage.cards.CardImpl; import mage.cards.CardSetInfo; import mage.constants.CardType; import mage.constants.Zone; -import mage.target.common.FilterCreatureAttackingYou; +import mage.filter.common.FilterCreatureAttackingYou; import mage.target.common.TargetCreaturePermanent; /** diff --git a/Mage.Sets/src/mage/cards/s/StalkingLeonin.java b/Mage.Sets/src/mage/cards/s/StalkingLeonin.java index 851483b435..2c5d8aec56 100644 --- a/Mage.Sets/src/mage/cards/s/StalkingLeonin.java +++ b/Mage.Sets/src/mage/cards/s/StalkingLeonin.java @@ -17,7 +17,7 @@ import mage.constants.Zone; import mage.game.Game; import mage.game.permanent.Permanent; import mage.players.Player; -import mage.target.common.FilterCreatureAttackingYou; +import mage.filter.common.FilterCreatureAttackingYou; import mage.target.common.TargetCreaturePermanent; import java.util.UUID; diff --git a/Mage/src/main/java/mage/filter/common/FilterCreatureAttackingYou.java b/Mage/src/main/java/mage/filter/common/FilterCreatureAttackingYou.java index d6e1555303..4657174caa 100644 --- a/Mage/src/main/java/mage/filter/common/FilterCreatureAttackingYou.java +++ b/Mage/src/main/java/mage/filter/common/FilterCreatureAttackingYou.java @@ -1,5 +1,5 @@ -package mage.target.common; +package mage.filter.common; import java.util.UUID; import mage.filter.common.FilterAttackingCreature;