mirror of
https://github.com/magefree/mage.git
synced 2026-01-10 12:52:06 -08:00
Merge branch 'master' of https://github.com/magefree/mage
This commit is contained in:
commit
07886811f0
14 changed files with 158 additions and 133 deletions
|
|
@ -182,7 +182,7 @@ class CorrosiveOozeCombatWatcher extends Watcher {
|
|||
if (event.getType() == GameEvent.EventType.BLOCKER_DECLARED) {
|
||||
Permanent attacker = game.getPermanent(event.getTargetId());
|
||||
Permanent blocker = game.getPermanent(event.getSourceId());
|
||||
if (attacker != null && attacker.getName().equals("Corrosive Ooze")) {
|
||||
if (attacker != null && attacker.getName().equals("Corrosive Ooze")) { // To check for name is not working if Ooze is copied but name changed
|
||||
if (blocker != null && hasAttachedEquipment(game, blocker)) {
|
||||
MageObjectReference oozeMor = new MageObjectReference(attacker, game);
|
||||
HashSet<MageObjectReference> relatedCreatures = oozeBlocksOrBlocked.getOrDefault(oozeMor, new HashSet<>());
|
||||
|
|
|
|||
|
|
@ -92,7 +92,7 @@ class JinxedIdolEffect extends ContinuousEffectImpl {
|
|||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
Permanent permanent = (Permanent) source.getSourceObjectIfItStillExists(game);
|
||||
Permanent permanent = source.getSourcePermanentIfItStillExists(game);
|
||||
if (permanent != null) {
|
||||
return permanent.changeControllerId(source.getFirstTarget(), game);
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -25,7 +25,6 @@
|
|||
* authors and should not be interpreted as representing official policies, either expressed
|
||||
* or implied, of BetaSteward_at_googlemail.com.
|
||||
*/
|
||||
|
||||
package mage.cards.m;
|
||||
|
||||
import java.util.UUID;
|
||||
|
|
@ -42,14 +41,16 @@ import mage.target.common.TargetCreaturePermanent;
|
|||
*/
|
||||
public class MutagenicGrowth extends CardImpl {
|
||||
|
||||
public MutagenicGrowth (UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{G/P}");
|
||||
public MutagenicGrowth(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{G/P}");
|
||||
|
||||
// ({GP} can be paid with either {G} or 2 life.)
|
||||
// Target creature gets +2/+2 until end of turn.
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanent());
|
||||
this.getSpellAbility().addEffect(new BoostTargetEffect(2, 2, Duration.EndOfTurn));
|
||||
}
|
||||
|
||||
public MutagenicGrowth (final MutagenicGrowth card) {
|
||||
public MutagenicGrowth(final MutagenicGrowth card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -52,10 +52,9 @@ import mage.target.common.TargetCreaturePermanent;
|
|||
public class Paralyze extends CardImpl {
|
||||
|
||||
public Paralyze(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.ENCHANTMENT},"{B}");
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{B}");
|
||||
this.subtype.add(SubType.AURA);
|
||||
|
||||
|
||||
// Enchant creature
|
||||
TargetPermanent auraTarget = new TargetCreaturePermanent();
|
||||
this.getSpellAbility().addTarget(auraTarget);
|
||||
|
|
@ -96,14 +95,18 @@ class ParalyzeEffect extends DoIfCostPaid {
|
|||
|
||||
@Override
|
||||
protected Player getPayingPlayer(Game game, Ability source) {
|
||||
Permanent attachment = game.getPermanent(source.getSourceId());
|
||||
Permanent attachedTo = game.getPermanent(attachment.getAttachedTo());
|
||||
return game.getPlayer(attachedTo.getControllerId());
|
||||
Permanent attachment = game.getPermanentOrLKIBattlefield(source.getSourceId());
|
||||
if (attachment != null && attachment.getAttachedTo() != null) {
|
||||
Permanent attachedTo = game.getPermanent(attachment.getAttachedTo());
|
||||
if (attachedTo != null) {
|
||||
return game.getPlayer(attachedTo.getControllerId());
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getText(Mode mode) {
|
||||
return new StringBuilder("that player may ").append(getCostText())
|
||||
.append(". If he or she does, ").append(executingEffects.getText(mode)).toString();
|
||||
return "that player may " + getCostText() + ". If he or she does, " + executingEffects.getText(mode);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue