Merge branch 'prowler' into 'master'

VOW: Cemetery Prowler and support

See merge request core-developers/forge!5735
This commit is contained in:
Michael Kamensky
2021-11-09 03:53:04 +00:00
2 changed files with 28 additions and 0 deletions

View File

@@ -2365,6 +2365,20 @@ public class AbilityUtils {
return doXMath(getCardTypesFromList(oppCards), expr, c, ctb);
}
//Count$TypesSharedWith [defined]
if (sq[0].startsWith("TypesSharedWith")) {
Set<CardType.CoreType> thisTypes = Sets.newHashSet(c.getType().getCoreTypes());
Set<CardType.CoreType> matches = new HashSet<>();
for (Card c1 : AbilityUtils.getDefinedCards(ctb.getHostCard(), l[0].split(" ")[1], ctb)) {
for (CardType.CoreType type : Sets.newHashSet(c1.getType().getCoreTypes())) {
if (thisTypes.contains(type)) {
matches.add(type);
}
}
}
return matches.size();
}
// Count$TopOfLibraryCMC
if (sq[0].equals("TopOfLibraryCMC")) {
int cmc = player.getCardsIn(ZoneType.Library).isEmpty() ? 0 :

View File

@@ -0,0 +1,14 @@
Name:Cemetery Prowler
ManaCost:1 G G
Types:Creature Wolf
PT:3/4
K:Vigilance
T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Card.Self | Execute$ TrigExile | TriggerDescription$ When CARDNAME enters the battlefield or attacks, exile a card from a graveyard.
T:Mode$ Attacks | ValidCard$ Card.Self | Execute$ TrigExile | Secondary$ True | TriggerDescription$ Whenever CARDNAME enters the battlefield or attacks, exile a card from a graveyard.
SVar:TrigExile:DB$ ChangeZone | Origin$ Graveyard | Destination$ Exile | ChangeType$ Card | ChangeNum$ 1 | SelectPrompt$ Select a card from a graveyard | Mandatory$ True | Hidden$ True | Imprint$ True
S:Mode$ ReduceCost | ValidCard$ Card | Type$ Spell | Amount$ AffectedX | Activator$ You | Description$ Spells you cast cost {1} less to cast for each card type they share with cards exiled with CARDNAME.
SVar:AffectedX:Count$TypesSharedWith Imprinted.ExiledWithSource
T:Mode$ ChangesZone | Origin$ Battlefield | ValidCard$ Card.Self | Destination$ Any | Execute$ DBCleanup | Static$ True
SVar:DBCleanup:DB$ Cleanup | ClearImprinted$ True
DeckHints:Ability$Graveyard & Ability$Discard
Oracle:Vigilance\nWhenever Cemetery Prowler enters the battlefield or attacks, exile a card from a graveyard.\nSpells you cast cost {1} less to cast for each card type they share with cards exiled with Cemetery Prowler.