diff --git a/projects/mtg/bin/Res/test/Blink_and_X_counters.txt b/projects/mtg/bin/Res/test/Blink_and_X_counters.txt new file mode 100644 index 000000000..9e12ff2eb --- /dev/null +++ b/projects/mtg/bin/Res/test/Blink_and_X_counters.txt @@ -0,0 +1,32 @@ +# Testing: when creature returns from blink, X is equal to 0 + +#Ivy Elemental +#{X}{G} +#Ivy Elemental enters the battlefield with X +1/+1 counters on it. + +#Flicker +#{1}{W} +#Exile target nontoken permanent, then return it to the battlefield under its owner's control. + +[INIT] +FIRSTMAIN +[PLAYER1] +hand:Flicker,Ivy Elemental +inplay:plains,mountain +manapool:{3}{G} +[PLAYER2] +[DO] +Ivy Elemental +# add mana to pool +plains +mountain +Flicker +Ivy Elemental +[ASSERT] +FIRSTMAIN +[PLAYER1] +graveyard:Flicker,Ivy Elemental +inplay:plains,mountain +manapool:{0} +[PLAYER2] +[END] \ No newline at end of file diff --git a/projects/mtg/bin/Res/test/_tests.txt b/projects/mtg/bin/Res/test/_tests.txt index 2f9efbfe0..6e235a07c 100644 --- a/projects/mtg/bin/Res/test/_tests.txt +++ b/projects/mtg/bin/Res/test/_tests.txt @@ -184,6 +184,7 @@ blessed_wind.txt blessed_wine.txt blinking_spirit.txt blinkmoth_nexus.txt +Blink_and_X_counters.txt bloated_toad1.txt bloated_toad2.txt bloodbond_march.txt diff --git a/projects/mtg/src/AllAbilities.cpp b/projects/mtg/src/AllAbilities.cpp index 277bab170..1eeae131b 100644 --- a/projects/mtg/src/AllAbilities.cpp +++ b/projects/mtg/src/AllAbilities.cpp @@ -5123,6 +5123,7 @@ void ABlink::resolveBlink() } spell->source->power = spell->source->origpower; spell->source->toughness = spell->source->origtoughness; + spell->source->X = 0; spell->resolve(); if(stored) {