mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-15 10:18:01 +00:00
Merge branch 'tibalt' into 'master'
Tibalt the Chaotic See merge request core-developers/forge!3960
This commit is contained in:
@@ -88,32 +88,32 @@ public class PlayEffect extends SpellAbilityEffect {
|
||||
}
|
||||
}
|
||||
else if (sa.hasParam("AnySupportedCard")) {
|
||||
List<PaperCard> cards = Lists.newArrayList(StaticData.instance().getCommonCards().getUniqueCards());
|
||||
final String valid = sa.getParam("AnySupportedCard");
|
||||
if (StringUtils.containsIgnoreCase(valid, "sorcery")) {
|
||||
List<PaperCard> cards = null;
|
||||
if (valid.startsWith("Names:")){
|
||||
cards = new ArrayList<>();
|
||||
for (String name : valid.substring(6).split(",")) {
|
||||
name = name.replace(";", ",");
|
||||
cards.add(StaticData.instance().getCommonCards().getUniqueByName(name));
|
||||
}
|
||||
} else if (valid.equalsIgnoreCase("sorcery")) {
|
||||
cards = Lists.newArrayList(StaticData.instance().getCommonCards().getUniqueCards());
|
||||
final Predicate<PaperCard> cpp = Predicates.compose(CardRulesPredicates.Presets.IS_SORCERY, PaperCard.FN_GET_RULES);
|
||||
cards = Lists.newArrayList(Iterables.filter(cards, cpp));
|
||||
}
|
||||
if (StringUtils.containsIgnoreCase(valid, "instant")) {
|
||||
} else if (valid.equalsIgnoreCase("instant")) {
|
||||
cards = Lists.newArrayList(StaticData.instance().getCommonCards().getUniqueCards());
|
||||
final Predicate<PaperCard> cpp = Predicates.compose(CardRulesPredicates.Presets.IS_INSTANT, PaperCard.FN_GET_RULES);
|
||||
cards = Lists.newArrayList(Iterables.filter(cards, cpp));
|
||||
}
|
||||
if (sa.hasParam("RandomCopied")) {
|
||||
final List<PaperCard> copysource = new ArrayList<>(cards);
|
||||
final CardCollection choice = new CardCollection();
|
||||
final String num = sa.hasParam("RandomNum") ? sa.getParam("RandomNum") : "1";
|
||||
int ncopied = AbilityUtils.calculateAmount(source, num, sa);
|
||||
while (ncopied > 0) {
|
||||
final PaperCard cp = Aggregates.random(copysource);
|
||||
for (PaperCard cp : Aggregates.random(cards, ncopied)) {
|
||||
final Card possibleCard = Card.fromPaperCard(cp, sa.getActivatingPlayer());
|
||||
// Need to temporarily set the Owner so the Game is set
|
||||
possibleCard.setOwner(sa.getActivatingPlayer());
|
||||
|
||||
if (possibleCard.isValid(valid, source.getController(), source, sa)) {
|
||||
choice.add(possibleCard);
|
||||
copysource.remove(cp);
|
||||
ncopied -= 1;
|
||||
}
|
||||
choice.add(possibleCard);
|
||||
}
|
||||
if (sa.hasParam("ChoiceNum")) {
|
||||
final int choicenum = AbilityUtils.calculateAmount(source, sa.getParam("ChoiceNum"), sa);
|
||||
|
||||
8
forge-gui/res/cardsfolder/t/tibalt_the_chaotic.txt
Normal file
8
forge-gui/res/cardsfolder/t/tibalt_the_chaotic.txt
Normal file
@@ -0,0 +1,8 @@
|
||||
Name:Tibalt the Chaotic
|
||||
ManaCost:1 R R
|
||||
Types:Legendary Planeswalker Tibalt
|
||||
Loyalty:4
|
||||
A:AB$ Play | Cost$ AddCounter<1/LOYALTY> | Planeswalker$ True | AnySupportedCard$ Names:Ignorant Bliss,Crack the Earth,Blazing Volley | RandomCopied$ True | CopyCard$ True | WithoutManaCost$ Trues | SpellDescription$ Cast a copy of one of the following cards chosen at random—Ignorant Bliss, Crack the Earth, Blazing Volley.
|
||||
A:AB$ Play | Cost$ SubCounter<3/LOYALTY> | Planeswalker$ True | AnySupportedCard$ Names:Seething Song,Dance with Devils,Flamebreak | RandomCopied$ True | CopyCard$ True | WithoutManaCost$ True | SpellDescription$ Cast a copy of one of the following cards chosen at random—Seething Song, Dance with Devils, Flamebreak.
|
||||
A:AB$ Play | Cost$ SubCounter<6/LOYALTY> | Planeswalker$ True | Ultimate$ True | AnySupportedCard$ Names:Hellion Eruption,Insurrection,Warp World | RandomCopied$ True | CopyCard$ True | WithoutManaCost$ True | SpellDescription$ Cast a copy of one of the following cards chosen at random—Hellion Eruption, Insurrection, Warp World.
|
||||
Oracle:[+1]: Cast a copy of one of the following cards chosen at random—Ignorant Bliss, Crack the Earth, Blazing Volley.[−3]: Cast a copy of one of the following cards chosen at random—Seething Song, Dance with Devils, Flamebreak.[−6]: Cast a copy of one of the following cards chosen at random—Hellion Eruption, Insurrection, Warp World.
|
||||
Reference in New Issue
Block a user