add support for yawgmoth's agenda and other similar cards
This commit is contained in:
@@ -220,7 +220,9 @@ class Constants
|
||||
NOLEGEND = 102,
|
||||
CANPLAYFROMGRAVEYARD = 103,
|
||||
TOKENIZER = 104,
|
||||
NB_BASIC_ABILITIES = 105,
|
||||
MYGRAVEEXILER = 105,
|
||||
OPPGRAVEEXILER = 106,
|
||||
NB_BASIC_ABILITIES = 107,
|
||||
|
||||
|
||||
RARITY_S = 'S', //Special Rarity
|
||||
|
||||
@@ -133,7 +133,9 @@ const char* Constants::MTGBasicAbilities[] = {
|
||||
"lure",
|
||||
"nolegend",
|
||||
"canplayfromgraveyard",
|
||||
"tokenizer"//parallel lives
|
||||
"tokenizer",//parallel lives,
|
||||
"mygraveexiler",
|
||||
"oppgraveexiler"
|
||||
};
|
||||
|
||||
map<string,int> Constants::MTGBasicAbilitiesMap;
|
||||
|
||||
@@ -321,6 +321,14 @@ MTGCardInstance * MTGPlayerCards::putInZone(MTGCardInstance * card, MTGGameZone
|
||||
return card; //Error check
|
||||
|
||||
int doCopy = 1;
|
||||
//Leyline of the Void, Yawgmoth's Agenda... effect...
|
||||
for(int i = 0; i < 2; ++i)
|
||||
{
|
||||
if ((to == g->players[i]->game->graveyard) && (
|
||||
g->players[i]->game->battlefield->hasAbility(Constants::MYGRAVEEXILER) ||
|
||||
g->players[i]->opponent()->game->battlefield->hasAbility(Constants::OPPGRAVEEXILER)))
|
||||
to = g->players[i]->game->exile;
|
||||
}
|
||||
//When a card is moved from inPlay to inPlay (controller change, for example), it is still the same object
|
||||
if ((to == g->players[0]->game->inPlay || to == g->players[1]->game->inPlay) && (from == g->players[0]->game->inPlay || from
|
||||
== g->players[1]->game->inPlay))
|
||||
|
||||
Reference in New Issue
Block a user