mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-18 19:58:00 +00:00
J22: Ogre Battlecaster (#2021)
* Mizzix and Ogre * Delete mizzix_replica_rider.txt * Update ogre_battlecaster.txt * Add support * Update ogre_battlecaster.txt * Create ogre_battlecaster.txt * Update ogre_battlecaster.txt * Update ogre_battlecaster.txt * Clean up Co-authored-by: TRT <>
This commit is contained in:
@@ -544,6 +544,9 @@ public final class GameActionUtil {
|
||||
if (sa.hasParam("ReduceCost")) {
|
||||
result.putParam("ReduceCost", sa.getParam("ReduceCost"));
|
||||
}
|
||||
if (sa.hasParam("RaiseCost")) {
|
||||
result.putParam("RaiseCost", sa.getParam("RaiseCost"));
|
||||
}
|
||||
for (OptionalCostValue v : list) {
|
||||
result.getPayCosts().add(v.getCost());
|
||||
result.addOptionalCost(v.getType());
|
||||
|
||||
@@ -396,6 +396,10 @@ public class PlayEffect extends SpellAbilityEffect {
|
||||
tgtSA.setSVar(reduce, sa.getSVar(reduce));
|
||||
}
|
||||
}
|
||||
if (sa.hasParam("PlayRaiseCost")) {
|
||||
String raise = sa.getParam("PlayRaiseCost");
|
||||
tgtSA.putParam("RaiseCost", raise);
|
||||
}
|
||||
|
||||
if (sa.hasParam("Madness")) {
|
||||
tgtSA.setAlternativeCost(AlternativeCost.Madness);
|
||||
@@ -509,7 +513,7 @@ public class PlayEffect extends SpellAbilityEffect {
|
||||
final Card hostCard = sa.getHostCard();
|
||||
final Game game = hostCard.getGame();
|
||||
final Player controller = sa.getActivatingPlayer();
|
||||
final String name = hostCard.getName() + "'s Effect";
|
||||
final String name = hostCard + "'s Effect";
|
||||
final String image = hostCard.getImageKey();
|
||||
final Card eff = createEffect(sa, controller, name, image);
|
||||
|
||||
|
||||
@@ -81,8 +81,14 @@ public class CostAdjustment {
|
||||
}
|
||||
}
|
||||
if (sa.hasParam("RaiseCost")) {
|
||||
int n = AbilityUtils.calculateAmount(host, sa.getParam("RaiseCost"), sa);
|
||||
result.add(new Cost(ManaCost.get(n), false));
|
||||
String raise = sa.getParam("RaiseCost");
|
||||
ManaCost mc;
|
||||
if (StringUtils.isNumeric(raise)) {
|
||||
mc = ManaCost.get(AbilityUtils.calculateAmount(host, raise, sa));
|
||||
} else {
|
||||
mc = new ManaCost(new ManaCostParser(raise));
|
||||
}
|
||||
result.add(new Cost(mc, false));
|
||||
}
|
||||
|
||||
// Raise cost
|
||||
|
||||
Reference in New Issue
Block a user