Merge pull request #665 from Northmoc/halaster

Scion of Halaster fix better
This commit is contained in:
Anthony Calosa
2022-06-12 13:48:31 +08:00
committed by GitHub
2 changed files with 12 additions and 2 deletions

View File

@@ -434,6 +434,16 @@ public abstract class CardTraitBase extends GameObject implements IHasCardView,
if (!Expressions.compare(sVar, svarOperator, operandValue)) {
return false;
}
if (hasParam("CheckSecondSVar")) {
final int sVar2 = AbilityUtils.calculateAmount(this.hostCard, getParam("CheckSecondSVar"), this);
final String comparator2 = getParamOrDefault("SecondSVarCompare", "GE1");
final String svarOperator2 = comparator2.substring(0, 2);
final String svarOperand2 = comparator2.substring(2);
final int operandValue2 = AbilityUtils.calculateAmount(this.hostCard, svarOperand2, this);
if (!Expressions.compare(sVar2, svarOperator2, operandValue2)) {
return false;
}
}
}
if (params.containsKey("ManaSpent")) {

View File

@@ -3,11 +3,11 @@ ManaCost:1 B
Types:Legendary Enchantment Background
S:Mode$ Continuous | Affected$ Creature.IsCommander+YouOwn | AddReplacementEffects$ Draw | Description$ Commander creatures you own have "The first time you would draw a card each turn, instead look at the top two cards of your library. Put one of them into your graveyard and the other back on top of your library. Then draw a card."
SVar:Draw:Event$ Draw | ValidPlayer$ You | ReplaceWith$ DBDig | CheckSVar$ X | SVarCompare$ EQ0 | CheckSecondSVar$ Y | SecondSVarCompare$ EQ0 | Description$ The first time you would draw a card each turn, instead look at the top two cards of your library. Put one of them into your graveyard and the other back on top of your library. Then draw a card.
SVar:DBDig:DB$ Dig | DigNum$ 2 | AnyNumber$ | DestinationZone$ Graveyard | LibraryPosition2$ 0 | SubAbility$ AllowDraw
SVar:DBDig:DB$ Dig | DigNum$ 2 | DestinationZone$ Graveyard | LibraryPosition2$ 0 | SubAbility$ AllowDraw
SVar:AllowDraw:DB$ StoreSVar | SVar$ Y | Type$ Number | Expression$ 1 | SubAbility$ DBDraw
SVar:DBDraw:DB$ Draw | SubAbility$ Reset
SVar:Reset:DB$ StoreSVar | SVar$ Y | Type$ Number | Expression$ 0
SVar:X:PlayerCountYou$CardsDrawn
SVar:X:Count$YouDrewThisTurn
SVar:Y:Number$0
DeckHas:Ability$Graveyard
AI:RemoveDeck:NonCommander