mirror of
https://github.com/correl/mage.git
synced 2024-12-25 11:11:16 +00:00
Replaced all usages of EmptyEffect by InfoEffect.
This commit is contained in:
parent
cc1d453a0b
commit
f31c317675
4 changed files with 6 additions and 68 deletions
|
@ -30,6 +30,7 @@ package mage.abilities.common;
|
||||||
import java.io.ObjectStreamException;
|
import java.io.ObjectStreamException;
|
||||||
import mage.abilities.MageSingleton;
|
import mage.abilities.MageSingleton;
|
||||||
import mage.abilities.StaticAbility;
|
import mage.abilities.StaticAbility;
|
||||||
|
import mage.abilities.effects.common.InfoEffect;
|
||||||
import mage.constants.Zone;
|
import mage.constants.Zone;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -50,7 +51,7 @@ public class CanBeYourCommanderAbility extends StaticAbility implements MageSing
|
||||||
}
|
}
|
||||||
|
|
||||||
private CanBeYourCommanderAbility() {
|
private CanBeYourCommanderAbility() {
|
||||||
super(Zone.ALL, new EmptyEffect("{this} can be your commander"));
|
super(Zone.ALL, new InfoEffect("{this} can be your commander"));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -1,63 +0,0 @@
|
||||||
/*
|
|
||||||
* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved.
|
|
||||||
*
|
|
||||||
* Redistribution and use in source and binary forms, with or without modification, are
|
|
||||||
* permitted provided that the following conditions are met:
|
|
||||||
*
|
|
||||||
* 1. Redistributions of source code must retain the above copyright notice, this list of
|
|
||||||
* conditions and the following disclaimer.
|
|
||||||
*
|
|
||||||
* 2. Redistributions in binary form must reproduce the above copyright notice, this list
|
|
||||||
* of conditions and the following disclaimer in the documentation and/or other materials
|
|
||||||
* provided with the distribution.
|
|
||||||
*
|
|
||||||
* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED
|
|
||||||
* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
|
||||||
* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR
|
|
||||||
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
|
||||||
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
|
||||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
|
|
||||||
* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
|
||||||
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
|
|
||||||
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
||||||
*
|
|
||||||
* The views and conclusions contained in the software and documentation are those of the
|
|
||||||
* authors and should not be interpreted as representing official policies, either expressed
|
|
||||||
* or implied, of BetaSteward_at_googlemail.com.
|
|
||||||
*/
|
|
||||||
package mage.abilities.common;
|
|
||||||
|
|
||||||
import mage.abilities.Ability;
|
|
||||||
import mage.abilities.effects.OneShotEffect;
|
|
||||||
import mage.constants.Outcome;
|
|
||||||
import mage.game.Game;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* This effect is used for adding rules on a card.
|
|
||||||
* It does nothing else.
|
|
||||||
*
|
|
||||||
* @author magenoxx_at_gmail.com
|
|
||||||
*/
|
|
||||||
public class EmptyEffect extends OneShotEffect {
|
|
||||||
|
|
||||||
public EmptyEffect(String rule) {
|
|
||||||
super(Outcome.Neutral);
|
|
||||||
staticText = rule;
|
|
||||||
}
|
|
||||||
|
|
||||||
public EmptyEffect(final EmptyEffect effect) {
|
|
||||||
super(effect);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public EmptyEffect copy() {
|
|
||||||
return new EmptyEffect(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public boolean apply(Game game, Ability source) {
|
|
||||||
// empty effect
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
|
@ -34,8 +34,8 @@ import java.util.Map;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
import mage.abilities.Ability;
|
import mage.abilities.Ability;
|
||||||
import mage.abilities.common.EmptyEffect;
|
|
||||||
import mage.abilities.common.SimpleStaticAbility;
|
import mage.abilities.common.SimpleStaticAbility;
|
||||||
|
import mage.abilities.effects.common.InfoEffect;
|
||||||
import mage.abilities.effects.common.continuous.CommanderManaReplacementEffect;
|
import mage.abilities.effects.common.continuous.CommanderManaReplacementEffect;
|
||||||
import mage.abilities.effects.common.continuous.CommanderReplacementEffect;
|
import mage.abilities.effects.common.continuous.CommanderReplacementEffect;
|
||||||
import mage.abilities.effects.common.cost.CommanderCostModification;
|
import mage.abilities.effects.common.cost.CommanderCostModification;
|
||||||
|
@ -74,7 +74,7 @@ public abstract class GameCommanderImpl extends GameImpl {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void init(UUID choosingPlayerId, GameOptions gameOptions) {
|
protected void init(UUID choosingPlayerId, GameOptions gameOptions) {
|
||||||
Ability ability = new SimpleStaticAbility(Zone.COMMAND, new EmptyEffect("Commander effects"));
|
Ability ability = new SimpleStaticAbility(Zone.COMMAND, new InfoEffect("Commander effects"));
|
||||||
//Move commander to command zone
|
//Move commander to command zone
|
||||||
for (UUID playerId: state.getPlayerList(startingPlayerId)) {
|
for (UUID playerId: state.getPlayerList(startingPlayerId)) {
|
||||||
Player player = getPlayer(playerId);
|
Player player = getPlayer(playerId);
|
||||||
|
|
|
@ -32,8 +32,8 @@ import java.util.HashSet;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
import mage.abilities.Ability;
|
import mage.abilities.Ability;
|
||||||
import mage.abilities.common.EmptyEffect;
|
|
||||||
import mage.abilities.common.SimpleStaticAbility;
|
import mage.abilities.common.SimpleStaticAbility;
|
||||||
|
import mage.abilities.effects.common.InfoEffect;
|
||||||
import mage.abilities.effects.common.continuous.CommanderManaReplacementEffect;
|
import mage.abilities.effects.common.continuous.CommanderManaReplacementEffect;
|
||||||
import mage.abilities.effects.common.continuous.CommanderReplacementEffect;
|
import mage.abilities.effects.common.continuous.CommanderReplacementEffect;
|
||||||
import mage.abilities.effects.common.cost.CommanderCostModification;
|
import mage.abilities.effects.common.cost.CommanderCostModification;
|
||||||
|
@ -69,7 +69,7 @@ public abstract class GameTinyLeadersImpl extends GameImpl{
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void init(UUID choosingPlayerId, GameOptions gameOptions) {
|
protected void init(UUID choosingPlayerId, GameOptions gameOptions) {
|
||||||
Ability ability = new SimpleStaticAbility(Zone.COMMAND, new EmptyEffect("Commander effects"));
|
Ability ability = new SimpleStaticAbility(Zone.COMMAND, new InfoEffect("Commander effects"));
|
||||||
//Move tiny leader to command zone
|
//Move tiny leader to command zone
|
||||||
for (UUID playerId: state.getPlayerList(startingPlayerId)) {
|
for (UUID playerId: state.getPlayerList(startingPlayerId)) {
|
||||||
Player player = getPlayer(playerId);
|
Player player = getPlayer(playerId);
|
||||||
|
|
Loading…
Reference in a new issue