mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-15 10:18:01 +00:00
- Converted Land Equilibrium to script
This commit is contained in:
@@ -1,7 +1,8 @@
|
||||
Name:Land Equilibrium
|
||||
ManaCost:2 U U
|
||||
Types:Enchantment
|
||||
Text:If an opponent who controls at least as many lands as you do would put a land onto the battlefield, that player instead puts that land onto the battlefield then sacrifices a land.
|
||||
SVar:SacLand:DB$ Sacrifice | SacValid$ Land | Defined$ Opponent | SpellDescription$ Opponent sacrifices a land
|
||||
R:Event$ Moved | ActiveZones$ Battlefield | Destination$ Battlefield | ValidCard$ Land.OppCtrl+ControllerControlsAtLeastAsManyLand | ReplaceWith$ MoveToPlay | Description$ If an opponent who controls at least as many lands as you do would put a land onto the battlefield, that player instead puts that land onto the battlefield then sacrifices a land.
|
||||
SVar:MoveToPlay:DB$ ChangeZone | Origin$ All | Destination$ Battlefield | Defined$ ReplacedCard | SubAbility$ SacLand
|
||||
SVar:SacLand:DB$ Sacrifice | SacValid$ Land | Defined$ ReplacedCardController
|
||||
SVar:Picture:http://www.wizards.com/global/images/magic/general/land_equilibrium.jpg
|
||||
Oracle:If an opponent who controls at least as many lands as you do would put a land onto the battlefield, that player instead puts that land onto the battlefield then sacrifices a land.
|
||||
@@ -5540,10 +5540,19 @@ public class Card extends GameEntity implements Comparable<Card> {
|
||||
}
|
||||
} else if (property.startsWith("ControllerControls")) {
|
||||
final String type = property.substring(18);
|
||||
if (type.startsWith("AtLeastAsMany")) {
|
||||
String realType = type.split("AtLeastAsMany")[1];
|
||||
List<Card> list = CardLists.getType(this.getController().getCardsIn(ZoneType.Battlefield), realType);
|
||||
List<Card> yours = CardLists.getType(sourceController.getCardsIn(ZoneType.Battlefield), realType);
|
||||
if (list.size() < yours.size()) {
|
||||
return false;
|
||||
}
|
||||
} else {
|
||||
final List<Card> list = this.getController().getCardsIn(ZoneType.Battlefield);
|
||||
if (CardLists.getType(list, type).isEmpty()) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
} else if (property.startsWith("Other")) {
|
||||
if (this.equals(source)) {
|
||||
return false;
|
||||
|
||||
@@ -84,7 +84,7 @@ public class PlayerZoneBattlefield extends PlayerZone {
|
||||
c.setSickness(true); // summoning sickness
|
||||
c.executeTrigger(ZCTrigger.ENTERFIELD);
|
||||
|
||||
if (c.isLand()) {
|
||||
/*if (c.isLand()) {
|
||||
|
||||
|
||||
for( Player opp : c.getOwner().getOpponents())
|
||||
@@ -97,7 +97,7 @@ public class PlayerZoneBattlefield extends PlayerZone {
|
||||
game.getStack().addSimultaneousStackEntry(abSac);
|
||||
}
|
||||
}
|
||||
} // isLand()
|
||||
} // isLand()*/
|
||||
}
|
||||
|
||||
if (game.getStaticEffects().getCardToEffectsList().containsKey(c.getName())) {
|
||||
|
||||
Reference in New Issue
Block a user