Merge branch 'master' of https://git.cardforge.org/core-developers/forge into ui-card-translation

This commit is contained in:
Peter
2019-08-15 08:06:37 +02:00
4 changed files with 16 additions and 9 deletions

View File

@@ -3,10 +3,8 @@ ManaCost:5 B B
Types:Creature Demon
PT:6/6
K:Flying
T:Mode$ DamageDone | ValidSource$ Card.OppCtrl | ValidTarget$ Card.Self | TriggerZones$ Battlefield | Execute$ TrigSacrifice | TriggerDescription$ Whenever a source an opponent controls deals damage to CARDNAME, that sources controller loses that much life unless they sacrifice that many permanents.
SVar:TrigSacrifice:DB$ Sacrifice | Defined$ TriggeredSourceController | SacValid$ Permanent | Amount$ X | References$ X | StrictAmount$ True | OptionalSacrifice$ True | RememberSacrificed$ True | SubAbility$ DBCurseDamage
SVar:DBCurseDamage:DB$ DealDamage | Defined$ TriggeredSourceController | NumDmg$ X | References$ X | ConditionDefined$ Remembered | ConditionPresent$ Card | ConditionCompare$ EQ0 | SubAbility$ DBCleanup
SVar:DBCleanup:DB$ Cleanup | ClearRemembered$ True
T:Mode$ DamageDone | ValidSource$ Card.OppCtrl | ValidTarget$ Card.Self | TriggerZones$ Battlefield | Execute$ DBLoseLife | TriggerDescription$ Whenever a source an opponent controls deals damage to CARDNAME, that sources controller loses that much life unless they sacrifice that many permanents.
SVar:DBLoseLife:DB$ LoseLife | Defined$ TriggeredSourceController | LifeAmount$ X | References$ X | UnlessCost$ Sac<X/Permanent> | UnlessPayer$ TriggeredSourceController
SVar:X:TriggerCount$DamageAmount
K:Madness:3 B B
Oracle:Flying\nWhenever a source an opponent controls deals damage to Archfiend of Spite, that sources controller loses that much life unless they sacrifice that many permanents.\nMadness {3}{B}{B} (If you discard this card, discard it into exile. When you do, cast it for its madness cost or put it into your graveyard.)

View File

@@ -569,10 +569,11 @@ public class HumanPlay {
return true;
}
else if (part instanceof CostSacrifice) {
int amount = Integer.parseInt(((CostSacrifice)part).getAmount());
CardCollectionView list = CardLists.getValidCards(p.getCardsIn(ZoneType.Battlefield), part.getType().split(";"), p, source, sourceAbility);
boolean hasPaid = payCostPart(controller, sourceAbility, (CostPartWithList)part, amount, list, "sacrifice." + orString);
if (!hasPaid) { return false; }
PaymentDecision pd = part.accept(hcd);
if (pd == null)
return false;
else
part.payAsDecided(p, pd, sourceAbility);
}
else if (part instanceof CostGainControl) {
int amount = Integer.parseInt(((CostGainControl)part).getAmount());