diff --git a/projects/mtg/bin/Res/sets/primitives/borderline.txt b/projects/mtg/bin/Res/sets/primitives/borderline.txt index 9e6ff93eb..77054a78b 100644 --- a/projects/mtg/bin/Res/sets/primitives/borderline.txt +++ b/projects/mtg/bin/Res/sets/primitives/borderline.txt @@ -1,7 +1,7 @@ grade=borderline #Bordeline Primitives Pack for Wagic the Homebrew. #Please keep these card alphabetized, and try to have the "name=" line at the top of each card -#I sorted this programmatically - Thanks to Vitty85 15-05-2023 +#I sorted this programmatically - Thanks to Vitty85 20-05-2023 [card] name=+2 Mace auto={3}:equip @@ -27192,6 +27192,18 @@ power=2 toughness=2 [/card] [card] +name=Essence of Orthodoxy +abilities=flying +auto=name(Incubate 2) name(Incubate 2) activate castcard(noevent costx!:2:! named!:Incubator:!) +auto=@movedto(other phyrexian|myBattlefield):name(Incubate 2) name(Incubate 2) activate castcard(noevent costx!:2:! named!:Incubator:!) +text=Flying -- Whenever Essence of Orthodoxy or another Phyrexian enters the battlefield under your control, incubate 2. (Create an Incubator token with two +1/+1 counters on it and "{2}: Transform this artifact." It transforms into a 0/0 Phyrexian artifact creature.) +mana={3}{W}{W} +type=Creature +subtype=Phyrexian +power=3 +toughness=3 +[/card] +[card] name=Essence of the Wild auto=@movedto(creature|mybattlefield):all(trigger[to]) transforms((,newability[copy all(Essence of the Wild)])) forever text=Creatures you control enter the battlefield as a copy of Essence of the Wild. @@ -60630,6 +60642,72 @@ power=1 toughness=1 [/card] [card] +name=Omnath, Locus of All +#MISSING: Check if revealed card has three or more colored mana symbols. +auto=mypoolsave(red) +auto=mypoolsave(white) +auto=mypoolsave(black) +auto=mypoolsave(green) +auto=mypoolsave(blue) +auto=mypoolsave(artifact) +auto=mypoolsave(land) +auto=@movedto(this|nonbattlezone) from(battlefield):name(Terminate effect) name(Terminate effect) transforms((,newability[mypoolsave(red) terminate],newability[mypoolsave(green) terminate],newability[mypoolsave(blue) terminate],newability[mypoolsave(black) terminate],newability[mypoolsave(white) terminate],newability[mypoolsave(artifact) terminate],newability[mypoolsave(land) terminate])) oneshot +auto=@each untap restriction{compare(mybluepoolcount)~morethan~0}:thisforeach(variable{mybluepoolcount}) add{B} && removemana({U}) +auto=@each untap restriction{compare(mygreenpoolcount)~morethan~0}:thisforeach(variable{mygreenpoolcount}) add{B} && removemana({G}) +auto=@each untap restriction{compare(myredpoolcount)~morethan~0}:thisforeach(variable{myredpoolcount})add{B} && removemana({R}) +auto=@each untap restriction{compare(mycolorlesspoolcount)~morethan~0}:thisforeach(variable{mycolorlesspoolcount}) add{B} && removemana({C}) +auto=@each untap restriction{compare(mywhitepoolcount)~morethan~0}:thisforeach(variable{mywhitepoolcount}) add{B} && removemana({W}) +auto=@each upkeep restriction{compare(mybluepoolcount)~morethan~0}:thisforeach(variable{mybluepoolcount}) add{B} && removemana({U}) +auto=@each upkeep restriction{compare(mygreenpoolcount)~morethan~0}:thisforeach(variable{mygreenpoolcount}) add{B} && removemana({G}) +auto=@each upkeep restriction{compare(myredpoolcount)~morethan~0}:thisforeach(variable{myredpoolcount})add{B} && removemana({R}) +auto=@each upkeep restriction{compare(mycolorlesspoolcount)~morethan~0}:thisforeach(variable{mycolorlesspoolcount}) add{B} && removemana({C}) +auto=@each upkeep restriction{compare(mywhitepoolcount)~morethan~0}:thisforeach(variable{mywhitepoolcount}) add{B} && removemana({W}) +auto=@each draw restriction{compare(mybluepoolcount)~morethan~0}:thisforeach(variable{mybluepoolcount}) add{B} && removemana({U}) +auto=@each draw restriction{compare(mygreenpoolcount)~morethan~0}:thisforeach(variable{mygreenpoolcount}) add{B} && removemana({G}) +auto=@each draw restriction{compare(myredpoolcount)~morethan~0}:thisforeach(variable{myredpoolcount})add{B} && removemana({R}) +auto=@each draw restriction{compare(mycolorlesspoolcount)~morethan~0}:thisforeach(variable{mycolorlesspoolcount}) add{B} && removemana({C}) +auto=@each draw restriction{compare(mywhitepoolcount)~morethan~0}:thisforeach(variable{mywhitepoolcount}) add{B} && removemana({W}) +auto=@each firstmain restriction{compare(mybluepoolcount)~morethan~0}:thisforeach(variable{mybluepoolcount}) add{B} && removemana({U}) +auto=@each firstmain restriction{compare(mygreenpoolcount)~morethan~0}:thisforeach(variable{mygreenpoolcount}) add{B} && removemana({G}) +auto=@each firstmain restriction{compare(myredpoolcount)~morethan~0}:thisforeach(variable{myredpoolcount})add{B} && removemana({R}) +auto=@each firstmain restriction{compare(mycolorlesspoolcount)~morethan~0}:thisforeach(variable{mycolorlesspoolcount}) add{B} && removemana({C}) +auto=@each firstmain restriction{compare(mywhitepoolcount)~morethan~0}:thisforeach(variable{mywhitepoolcount}) add{B} && removemana({W}) +auto=@each combatbegins restriction{compare(mybluepoolcount)~morethan~0}:thisforeach(variable{mybluepoolcount}) add{B} && removemana({U}) +auto=@each combatbegins restriction{compare(mygreenpoolcount)~morethan~0}:thisforeach(variable{mygreenpoolcount}) add{B} && removemana({G}) +auto=@each combatbegins restriction{compare(myredpoolcount)~morethan~0}:thisforeach(variable{myredpoolcount})add{B} && removemana({R}) +auto=@each combatbegins restriction{compare(mycolorlesspoolcount)~morethan~0}:thisforeach(variable{mycolorlesspoolcount}) add{B} && removemana({C}) +auto=@each combatbegins restriction{compare(mywhitepoolcount)~morethan~0}:thisforeach(variable{mywhitepoolcount}) add{B} && removemana({W}) +auto=@each combatends restriction{compare(mybluepoolcount)~morethan~0}:thisforeach(variable{mybluepoolcount}) add{B} && removemana({U}) +auto=@each combatends restriction{compare(mygreenpoolcount)~morethan~0}:thisforeach(variable{mygreenpoolcount}) add{B} && removemana({G}) +auto=@each combatends restriction{compare(myredpoolcount)~morethan~0}:thisforeach(variable{myredpoolcount})add{B} && removemana({R}) +auto=@each combatends restriction{compare(mycolorlesspoolcount)~morethan~0}:thisforeach(variable{mycolorlesspoolcount}) add{B} && removemana({C}) +auto=@each combatends restriction{compare(mywhitepoolcount)~morethan~0}:thisforeach(variable{mywhitepoolcount}) add{B} && removemana({W}) +auto=@each secondmain restriction{compare(mybluepoolcount)~morethan~0}:thisforeach(variable{mybluepoolcount}) add{B} && removemana({U}) +auto=@each secondmain restriction{compare(mygreenpoolcount)~morethan~0}:thisforeach(variable{mygreenpoolcount}) add{B} && removemana({G}) +auto=@each secondmain restriction{compare(myredpoolcount)~morethan~0}:thisforeach(variable{myredpoolcount})add{B} && removemana({R}) +auto=@each secondmain restriction{compare(mycolorlesspoolcount)~morethan~0}:thisforeach(variable{mycolorlesspoolcount}) add{B} && removemana({C}) +auto=@each secondmain restriction{compare(mywhitepoolcount)~morethan~0}:thisforeach(variable{mywhitepoolcount}) add{B} && removemana({W}) +auto=@each endofturn restriction{compare(mybluepoolcount)~morethan~0}:thisforeach(variable{mybluepoolcount}) add{B} && removemana({U}) +auto=@each endofturn restriction{compare(mygreenpoolcount)~morethan~0}:thisforeach(variable{mygreenpoolcount}) add{B} && removemana({G}) +auto=@each endofturn restriction{compare(myredpoolcount)~morethan~0}:thisforeach(variable{myredpoolcount})add{B} && removemana({R}) +auto=@each endofturn restriction{compare(mycolorlesspoolcount)~morethan~0}:thisforeach(variable{mycolorlesspoolcount}) add{B} && removemana({C}) +auto=@each endofturn restriction{compare(mywhitepoolcount)~morethan~0}:thisforeach(variable{mywhitepoolcount}) add{B} && removemana({W}) +auto=@each cleanup restriction{compare(mybluepoolcount)~morethan~0}:thisforeach(variable{mybluepoolcount}) add{B} && removemana({U}) +auto=@each cleanup restriction{compare(mygreenpoolcount)~morethan~0}:thisforeach(variable{mygreenpoolcount}) add{B} && removemana({G}) +auto=@each cleanup restriction{compare(myredpoolcount)~morethan~0}:thisforeach(variable{myredpoolcount})add{B} && removemana({R}) +auto=@each cleanup restriction{compare(mycolorlesspoolcount)~morethan~0}:thisforeach(variable{mycolorlesspoolcount}) add{B} && removemana({C}) +auto=@each cleanup restriction{compare(mywhitepoolcount)~morethan~0}:thisforeach(variable{mywhitepoolcount}) add{B} && removemana({W}) +aicode=activate transforms((,newability[all(*[zpos=1]|mylibrary) moveto(myhand)])) oneshot +auto=@each my firstmain:name(Look top card) reveal:1 optionone name(Put in hand) target(*|reveal) moveto(myhand) oneshot optiononeend optiontwo all(*|reveal) moveto(myhand) optiontwoend revealend +text=If you would lose unspent mana, that mana becomes black instead. -- At the beginning of your precombat main phase, look at the top card of your library. You may reveal that card if it has three or more colored mana symbols in its mana cost. If you do, add three mana in any combination of its colors and put it into your hand. If you don't reveal it, put it into your hand. +other={W}{U}{R}{G}{L:2} name(Pay 2 life) +mana={W}{U}{B}{R}{G} +type=Legendary Creature +subtype=Phyrexian Elemental +power=4 +toughness=4 +[/card] +[card] name=Omnath, Locus of Creation auto=draw:1 controller auto=@movedTo(land|myBattlefield) restriction{thisturn(land[fresh]|myBattlefield)~equalto~0}:life:4 controller @@ -65933,7 +66011,7 @@ toughness=5 [/card] [card] name=Protocol Knight -auto=if type(other *[knight]|mybattlefield)~morethan~0 then name(Stun creature) name(Stun creature) target(creature|opponentbattlefield) transforms((,newability[tap],newability[counter(0/0.1.Stun)],newability[this(counter{0/0.1.Stun}>=1) doesnotuntap],newability[@each my untap restriction{compare(hascntstun)~morethan~0}:name(Remove a stun counter) name(Remove a stun counter) counter(0/0.-1.Stun)])) forever +auto=if type(other *[knight]|mybattlefield)~morethan~0 then name(Stun creature) name(Stun creature) target(creature|opponentbattlefield) transforms((,newability[tap],newability[counter(0/0.1.Stun)])) oneshot auto=if type(other *[knight]|mybattlefield)~equalto~0 then name(Tap creature) name(Tap creature) target(creature|opponentbattlefield) tap text=When Protocol Knight enters the battlefield, tap target creature an opponent controls. Put a stun counter on that creature if you control another Knight. (If a permanent with a stun counter would become untapped, remove one from it instead.) mana={3}{U} @@ -66997,6 +67075,19 @@ power=2 toughness=4 [/card] [card] +name=Quintorius, Loremaster +abilities=vigilance +auto=@each my endofturn:name(Exile a card) target(*[-creature;-land]|mygraveyard) moveto(myexile) and!( counter(0/0.1.QuintoriusExiled) notrg )! +auto=@each my endofturn:name(Create spirit) token(Spirit,Creature Spirit,3/2,red,white) +auto={1}{R}{W}{T}{S(spirit|myBattlefield)}:name(Choose exiled card) target(*[counter{0/0.1.QuintoriusExiled}]|myexile) transforms((,newability[zerocast],newability[canplayfromexile],newability[bottomlibrarydeath])) ueot +text=Vigilance -- At the beginning of your end step, exile target noncreature, nonland card from your graveyard. Create a 3/2 red and white Spirit creature token. -- {1}{R}{W}, {T}, Sacrifice a Spirit: Choose target card exiled with Quintorius. You may cast that card this turn without paying its mana cost. If that spell would be put into a graveyard, put it on the bottom of its owner's library instead. +mana={3}{R}{W} +type=Legendary Creature +subtype=Elephant Cleric +power=3 +toughness=5 +[/card] +[card] name=Quirion Explorer auto=this(variable{olandg}>0) {t}:out{g} auto=this(variable{olandu}>0) {t}:out{u} @@ -68008,6 +68099,22 @@ power=3 toughness=1 [/card] [card] +name=Rankle and Torbran +abilities=first strike,flying,haste +auto=@combatdamaged(player) from(this):may name(Create treasure) token(Treasure Sur) and!( token(Treasure Sur) opponent )! +auto=@combatdamaged(player) from(this):may name(Each player sacrifices) target(creature|myBattlefield) sacrifice and!( transforms((,newability[ability$!name(Sacrifice a creature) notatarget(creature|myBattlefield) sacrifice!$ opponent])) oneshot )! +auto=@combatdamaged(player) from(this):may name(Duouble the damage) token(Rankle Emblem,Emblem,0/0,shroud,indestructible,treason,notrigger) and!( transforms((,newability[@damaged(battle|battlefield) from(*[-Rankle Emblem]|*):all(trigger[to]) damage:2],newability[@damageof(player) from(*[-Rankle Emblem]|*):damage:2 controller],newability[@damagefoeof(player) from(*[-Rankle Emblem]|*):damage:2 opponent])) forever )! +auto=@combatdamaged(battle) from(this):may name(Create treasure) token(Treasure Sur) and!( token(Treasure Sur) opponent )! +auto=@combatdamaged(battle) from(this):may name(Each player sacrifices) target(creature|myBattlefield) sacrifice and!( transforms((,newability[ability$!name(Sacrifice a creature) notatarget(creature|myBattlefield) sacrifice!$ opponent])) oneshot )! +auto=@combatdamaged(battle) from(this):may name(Duouble the damage) token(Rankle Emblem,Emblem,0/0,shroud,indestructible,treason,notrigger) and!( transforms((,newability[@damaged(battle|battlefield) from(*[-Rankle Emblem]|*):all(trigger[to]) damage:2],newability[@damageof(player) from(*[-Rankle Emblem]|*):damage:2 controller],newability[@damagefoeof(player) from(*[-Rankle Emblem]|*):damage:2 opponent])) forever )! +text=Flying, first strike, haste -- Whenever Rankle and Torbran deals combat damage to a player or battle, choose any number -- Each player creates a Treasure token. -- Each player sacrifices a creature. -- If a source would deal damage to a player or battle this turn, it deals that much damage plus 2 instead. +mana={1}{B}{B}{R}{R} +type=Legendary Creature +subtype=Faerie Dwarf +power=3 +toughness=4 +[/card] +[card] name=Rankle, Master of Pranks abilities=flying,haste auto=@combatdamaged(player) from(this):may name(discard) transforms((,newability[ability$!name(discard) notatarget(*|myhand) reject!$ controller],newability[ability$!name(discard) notatarget(*|myhand) reject!$ opponent])) ueot @@ -68546,6 +68653,14 @@ power=7 toughness=7 [/card] [card] +name=Realmbreaker, the Invasion Tree +auto={2}{T}:name(Opponent mills 3 cards) deplete:3 opponent && ability$!name(Put land in play) target(land|opponentgraveyard) moveto(mybattlefield) and!( transforms((,newability[tap(noevent)],newability[exiledeath])) forever )!!$ controller +auto={10}{T}{S}:name(Search praetors) target(praetor|mylibrary) moveto(mybattlefield) and!( shuffle )! +text={2}, {T}: Target opponent mills three cards. Put a land card from their graveyard onto the battlefield tapped under your control. It gains "If this land would leave the battlefield, exile it instead of putting it anywhere else." -- {10}, {T}, Sacrifice Realmbreaker, the Invasion Tree: Search your library for any number of Praetor cards, put them onto the battlefield, then shuffle. +mana={3} +type=Legendary Artifact +[/card] +[card] name=Realmbreaker's Grasp target=artifact,creature auto=teach(creature) cantattack @@ -69003,6 +69118,17 @@ power=0 toughness=1 [/card] [card] +name=Referee Squad +abilities=vigilance +auto=name(Stun creature) target(creature|opponentbattlefield) transforms((,newability[tap],newability[counter(0/0.1.Stun)])) oneshot +text=Convoke (Your creatures can help cast this spell. Each creature you tap while casting this spell pays for {1} or one mana of that creature's color.) -- Vigilance -- When Referee Squad enters the battlefield, tap target creature an opponent controls and put a stun counter on it. (If a permanent with a stun counter would become untapped, remove one from it instead.) +mana={2}{U} +type=Creature +subtype=Homunculus +power=2 +toughness=2 +[/card] +[card] name=Reflections of Littjara auto=chooseatype all(this) transforms((,newability[@movedTo(*[chosentype]|mystack):all(trigger[to]) clone])) forever chooseend text=As Reflections of Littjara enters the battlefield, choose a creature type. -- Whenever you cast a spell of the chosen type, copy that spell. (A copy of a permanent spell becomes a token.) @@ -74843,6 +74969,14 @@ power=3 toughness=4 [/card] [card] +name=Sculpted Perfection +auto=name(Incubate 2) name(Incubate 2) activate castcard(noevent costx!:2:! named!:Incubator:!) +auto=lord(phyrexian|myBattlefield) +1/+1 +text=When Sculpted Perfection enters the battlefield, incubate 2. (Create an Incubator token with two +1/+1 counters on it and "{2}: Transform this artifact." It transforms into a 0/0 Phyrexian artifact creature.) -- Phyrexians you control get +1/+1. +mana={2}{W}{B} +type=Enchantment +[/card] +[card] name=Sculpted Sunburst target=creature|mybattlefield auto=moveto(mybattlefield) and!( all(other creature[mybattlefield]) moveto(exile) )! @@ -75442,6 +75576,17 @@ mana={G} type=Instant [/card] [card] +name=Seedpod Caretaker +auto=if type(*[artifact;creature]|mybattlefield)~morethan~0 then choice name(Put 1/1 counter) name(Put 1/1 counter) target(*[artifact;creature]|mybattlefield) counter(1/1) +auto=if type(incubator|mybattlefield)~morethan~0 then choice name(Transform incubator) name(Transform incubator) target(incubator|mybattlefield) flip(backside) +text=When Seedpod Caretaker enters the battlefield, choose one -- Put a +1/+1 counter on target artifact or creature you control. -- Transform target Incubator token you control. +mana={2}{W} +type=Creature +subtype=Phyrexian Cleric +power=2 +toughness=2 +[/card] +[card] name=Seeds of Strength target=creature auto=1/1 ueot @@ -75473,6 +75618,18 @@ power=1 toughness=2 [/card] [card] +name=Seer of Stolen Sight +abilities=menace +aicode=activate transforms((,newability[surveil],newability[all(*[zpos<=psurveiloffsetplus1plusend]|mylibrary) transforms((,newability[if compare(genrand2)~equalto~1 then moveto(mygraveyard)])) oneshot])) oneshot +auto=@movedto(*[creature;artifact]|graveyard) from(myBattlefield):name(Surveil 1) reveal:psurveiloffsetplus1plusend optionone name(put in graveyard) target(*|reveal) moveto(ownergraveyard) optiononeend optiontwo name(put in library) target(*|reveal) moveto(ownerlibrary) optiontwoend afterrevealed surveil afterrevealedend revealend +text=Menace (This creature can't be blocked except by two or more creatures.) -- Whenever one or more artifacts and/or creatures you control are put into a graveyard from the battlefield, surveil 1. (Look at the top card of your library. You may put that card into your graveyard.) +mana={2}{B} +type=Creature +subtype=Phyrexian Warlock +power=2 +toughness=3 +[/card] +[card] name=Seer of the Last Tomorrow auto={U}{T}{D(*|myhand)}:deplete:3 target(player) text={U}, {T}, Discard a card: Target player mills three cards. @@ -100390,6 +100547,17 @@ power=8 toughness=8 [/card] [card] +name=Zimone and Dina +auto=_SECOND_DRAW_name(Gain life) life:-2 opponent && life:2 controller +auto={T}{S(other creature|mybattlefield)}:name(Draw a card) transforms((,newability[draw:1 controller],newability[may name(Put land in play) target(land|myhand) moveto(mybattlefield) and!( transforms((,newability[tap(noevent)],newability[if type(land|mybattlefield)~morethan~7 then name(Put land in play) draw:1 controller && ability$!may name(Put land in play) target(land|myhand) moveto(mybattlefield) and!( tap(noevent) )! !$ controller])) oneshot )!])) oneshot )! +text=Whenever you draw your second card each turn, target opponent loses 2 life and you gain 2 life. -- {T}, Sacrifice another creature: Draw a card. You may put a land card from your hand onto the battlefield tapped. If you control eight or more lands, repeat this process once. +mana={B}{G}{U} +type=Legendary Creature +subtype=Human Dryad +power=3 +toughness=4 +[/card] +[card] name=Zimone, Quandrix Prodigy auto={1}{T}:name(Put land in play) target(land|myhand) moveto(mybattlefield) and!( tap(noevent) )! auto=this(variable{type:land:mybattlefield}<8) {4}{T}:name(Draw 1 card) draw:1 controller @@ -100497,6 +100665,20 @@ power=1 toughness=4 [/card] [card] +name=Zurgo and Ojutai +abilities=flying,haste +aicode=activate target(*[zpos<=3]|mylibrary) moveto(myhand) and!( transforms((,newability[may name(Return dragon) target(dragon[attacking]|mybattlefield) moveto(ownerhand)],newability[all(*[zpos<=3]|mylibrary) moveto(myreveal) and!( bottomoflibrary )!])) oneshot )! +auto=@combatdamaged(player) from(dragon|mybattlefield) turnlimited:name(Look top 3 cards) reveal:3 optionone name(Get a card) target(*|reveal) moveto(myhand) optiononeend optiontwo name(put on bottom) target(<3>*|reveal) bottomoflibrary optiontwoend afterrevealed may name(Return dragon to hand) target(dragon[attacking]|mybattlefield) moveto(ownerhand) afterrevealedend revealend +auto=@combatdamaged(battle) from(dragon|mybattlefield) turnlimited:name(Look top 3 cards) reveal:3 optionone name(Get a card) target(*|reveal) moveto(myhand) optiononeend optiontwo name(put on bottom) target(<3>*|reveal) bottomoflibrary optiontwoend afterrevealed may name(Return dragon to hand) target(dragon[attacking]|mybattlefield) moveto(ownerhand) afterrevealedend revealend +auto=transforms((,newability[opponentshroud])) ueot +text=Flying, haste -- Zurgo and Ojutai has hexproof as long as it entered the battlefield this turn. -- Whenever one or more Dragons you control deal combat damage to a player or battle, look at the top three cards of your library. Put one of them into your hand and the rest on the bottom of your library in any order. You may return one of those Dragons to its owner's hand. +mana={2}{U}{R}{W} +type=Legendary Creature +subtype=Orc Dragon +power=4 +toughness=4 +[/card] +[card] name=Zurzoth, Chaos Rider auto=@drawfoeof(player) restriction{myturnonly} turnlimited:name(Create Devil) token(Devil,Creature Devil,1/1,red) and!( transforms((,newability[@movedto(this|mygraveyard):damage:1 target(*[player;creature;planeswalker])])) forever )! auto=@combat(attacking) source(devil|myBattlefield) turnlimited:name(Draw and discard) draw:1 && discard:1 diff --git a/projects/mtg/bin/Res/sets/primitives/mtg.txt b/projects/mtg/bin/Res/sets/primitives/mtg.txt index a5d3610ee..c4f3ea942 100644 --- a/projects/mtg/bin/Res/sets/primitives/mtg.txt +++ b/projects/mtg/bin/Res/sets/primitives/mtg.txt @@ -1,6 +1,6 @@ #Primitives Pack for Wagic the Homebrew. #Please keep these card alphabetized, and try to have the "name=" line at the top of each card -#I sorted this programatically so the other comments are removed except for AUTO_DEFINE - Vitty85 21-12-2021 +#I sorted this programatically so the other comments are removed except for AUTO_DEFINE - Vitty85 20-05-2023 [card] name=Abandon Reason target=creature diff --git a/projects/mtg/bin/Res/sets/primitives/planeswalkers.txt b/projects/mtg/bin/Res/sets/primitives/planeswalkers.txt index 2d0210330..aabc466c6 100644 --- a/projects/mtg/bin/Res/sets/primitives/planeswalkers.txt +++ b/projects/mtg/bin/Res/sets/primitives/planeswalkers.txt @@ -1,6 +1,6 @@ #Planeswalkers Primitives Pack for Wagic the Homebrew. #Please keep these card alphabetized, and try to have the "name=" line at the top of each card -#We sorted this in alphabetical order - Luruz & Vitty85 21-12-2021 +#We sorted this in alphabetical order - Luruz & Vitty85 20-05-2023 [card] name=Abian, Luvion Usurper auto=counter(0/0,5,loyalty) diff --git a/projects/mtg/bin/Res/sets/primitives/unsupported.txt b/projects/mtg/bin/Res/sets/primitives/unsupported.txt index fd72dce18..ac8fd85dc 100644 --- a/projects/mtg/bin/Res/sets/primitives/unsupported.txt +++ b/projects/mtg/bin/Res/sets/primitives/unsupported.txt @@ -2,7 +2,7 @@ grade=unsupported #The cards in this file are not implemented/incomplete yet. #Updated Card lists not in primitives (Borderline, Crappy, Unsupported and Missing Cards) #Please keep these card alphabetized, and try to have the "name=" line at the top of each card -#I sorted this programatically - Vitty85 10-05-2023 +#I sorted this programatically - Vitty85 20-05-2023 [card] name="Ach! Hans, Run!" text=At the beginning of your upkeep, you may say "Ach Hans, run It's the . . ." and name a creature card. If you do, search your library for the named card, put it into play, then shuffle your library. That creature has haste. Remove it from the game at end of turn. diff --git a/projects/mtg/include/MTGDefinitions.h b/projects/mtg/include/MTGDefinitions.h index 8076d1c65..1f9a85177 100644 --- a/projects/mtg/include/MTGDefinitions.h +++ b/projects/mtg/include/MTGDefinitions.h @@ -340,7 +340,8 @@ class Constants NONIGHT = 212, NODAMAGEREMOVED = 213, BACKGROUNDPARTNER = 214, - NB_BASIC_ABILITIES = 215, + BOTTOMLIBRARYDEATH = 215, + NB_BASIC_ABILITIES = 216, RARITY_S = 'S', //Special Rarity RARITY_M = 'M', //Mythics diff --git a/projects/mtg/src/MTGDefinitions.cpp b/projects/mtg/src/MTGDefinitions.cpp index 1bfc294fd..3fa1f1ce7 100644 --- a/projects/mtg/src/MTGDefinitions.cpp +++ b/projects/mtg/src/MTGDefinitions.cpp @@ -245,7 +245,8 @@ const char* Constants::MTGBasicAbilities[] = { "countershroud", //Card can't get any kind of counter (e.g. "Solemnity"). "nonight", //It can't become night (e.g. "Angel of Eternal Dawn"). "nodamageremoved", //Damage is not removed from card (e.g. "Patient Zero"). - "backgroundpartner" //Can choose a backgorund partner as commander (e.g. "Faceless One"). + "backgroundpartner", //Can choose a backgorund partner as commander (e.g. "Faceless One"). + "bottomlibrarydeath" //It goes to bottom of library after death (e.g. "Quintorius, Loremaster"). }; map Constants::MTGBasicAbilitiesMap; diff --git a/projects/mtg/src/MTGGameZones.cpp b/projects/mtg/src/MTGGameZones.cpp index f3ec3254b..02177f822 100644 --- a/projects/mtg/src/MTGGameZones.cpp +++ b/projects/mtg/src/MTGGameZones.cpp @@ -475,7 +475,8 @@ MTGCardInstance * MTGPlayerCards::putInZone(MTGCardInstance * card, MTGGameZone return card; //Error check int doCopy = 1; - bool shufflelibrary = card->basicAbilities[(int)Constants::SHUFFLELIBRARYDEATH]; + bool shufflelibrary = false; + bool bottomoflibrary = false; bool inplaytoinplay = false; bool ripToken = false; if (card->discarderOwner) @@ -496,10 +497,13 @@ MTGCardInstance * MTGPlayerCards::putInZone(MTGCardInstance * card, MTGGameZone { if ((to == g->players[i]->game->graveyard) && ( card->basicAbilities[(int)Constants::LIBRARYDEATH]|| + card->basicAbilities[(int)Constants::BOTTOMLIBRARYDEATH]|| card->basicAbilities[(int)Constants::SHUFFLELIBRARYDEATH])) { to = g->players[i]->game->library; - } + shufflelibrary = card->basicAbilities[(int)Constants::SHUFFLELIBRARYDEATH]; + bottomoflibrary = card->basicAbilities[(int)Constants::BOTTOMLIBRARYDEATH]; + } } //Leyline of the Void, Yawgmoth's Agenda... effect... for(int i = 0; i < 2; ++i) @@ -551,6 +555,19 @@ MTGCardInstance * MTGPlayerCards::putInZone(MTGCardInstance * card, MTGGameZone if (!(copy = from->removeCard(card, doCopy))) return NULL; //ERROR + for(int i = 0; i < 2; ++i) + { + if ((to == g->players[i]->game->battlefield || to == g->players[i]->game->stack) && ( + card->basicAbilities[(int)Constants::LIBRARYDEATH]|| + card->basicAbilities[(int)Constants::BOTTOMLIBRARYDEATH]|| + card->basicAbilities[(int)Constants::SHUFFLELIBRARYDEATH])) + { + copy->basicAbilities[Constants::LIBRARYDEATH] = card->basicAbilities[Constants::LIBRARYDEATH]; + copy->basicAbilities[Constants::BOTTOMLIBRARYDEATH] = card->basicAbilities[Constants::BOTTOMLIBRARYDEATH]; + copy->basicAbilities[Constants::SHUFFLELIBRARYDEATH] = card->basicAbilities[Constants::SHUFFLELIBRARYDEATH]; + } + } + // Set the mana value used to cast this spell if((to == g->players[0]->game->stack || to == g->players[1]->game->stack) && card->getManaCost() && card->getManaCost()->getManaUsedToCast()){ copy->getManaCost()->setManaUsedToCast(NEW ManaCost()); @@ -742,7 +759,21 @@ MTGCardInstance * MTGPlayerCards::putInZone(MTGCardInstance * card, MTGGameZone if(!asCopy) { if(shufflelibrary) - copy->owner->game->library->shuffle();//shouldnt we only ever do this if you clicked close on your library gui?????? + copy->owner->game->library->shuffle(); + + if(bottomoflibrary){ + MTGLibrary * library = copy->owner->game->library; + vectoroldOrder = library->cards; + vectornewOrder; + newOrder.push_back(copy); + for(unsigned int k = 0;k < oldOrder.size();++k) + { + MTGCardInstance * rearranged = oldOrder[k]; + if(rearranged != copy) + newOrder.push_back(rearranged); + } + library->cards = newOrder; + } if(copy->has(Constants::ADVENTURE) && copy->alternateCostPaid[ManaCost::MANA_PAID_WITH_ALTERNATIVE] == 1 && //Added to correctly set the adventure cards type on stack. (to == g->players[0]->game->stack || to == g->players[1]->game->stack)){