diff --git a/projects/mtg/bin/Res/sets/USG/_cards.dat b/projects/mtg/bin/Res/sets/USG/_cards.dat index 3fc9c3543..b581226bf 100644 --- a/projects/mtg/bin/Res/sets/USG/_cards.dat +++ b/projects/mtg/bin/Res/sets/USG/_cards.dat @@ -427,6 +427,15 @@ type=Basic Land subtype=Forest [/card] [card] +text={T}: Add {G} to your mana pool for each creature you control. +id=10422 +auto={T}:foreach(creature|myinplay)add:{G} +name=Gaea's Cradle +rarity=R +type=Land +abilities=legendary +[/card] +[card] text=Enchant creature Enchanted creature gets +3/+3 and has trample. {G}: Regenerate enchanted creature. target=creature auto=3/3 diff --git a/projects/mtg/bin/Res/sets/USG/todo.dat b/projects/mtg/bin/Res/sets/USG/todo.dat index 32eb17f4d..7a24c8861 100644 --- a/projects/mtg/bin/Res/sets/USG/todo.dat +++ b/projects/mtg/bin/Res/sets/USG/todo.dat @@ -701,14 +701,6 @@ rarity=C type=Sorcery mana={2}{G} [/card] -[card] -text={T}: Add {G} to your mana pool for each creature you control. -id=10422 -name=Gaea's Cradle -rarity=R -type=Legendary Land -[/card] - [card] text=Flying When Gilded Drake comes into play, exchange control of Gilded Drake and up to one target creature an opponent controls. If you don't make an exchange, sacrifice Gilded Drake. This ability can't be countered except by spells and abilities. (This effect doesn't end at end of turn.) id=5837 diff --git a/projects/mtg/src/MTGAbility.cpp b/projects/mtg/src/MTGAbility.cpp index 1a3ed9839..6059b4348 100644 --- a/projects/mtg/src/MTGAbility.cpp +++ b/projects/mtg/src/MTGAbility.cpp @@ -964,17 +964,28 @@ int AbilityFactory::magicText(int id, Spell * spell, MTGCardInstance * card){ if (input->isNull()){ SAFE_DELETE(input); } - MTGAbility * a = NEW AManaProducer(id, target, output, input,doTap); - if (multi){ + MTGAbility * a = NEW AManaProducer(id, target, output, input,doTap); + ManaCost * FinalOutput = NEW ManaCost(); + if (lordType == PARSER_FOREACH){ + int multiplier = countCards(lordTargets); + for (int i = 0; i < Constants::MTG_NB_COLORS; i++){ + if (output->hasColor(i)){ + FinalOutput->add(i,multiplier); + } + } + game->addObserver (NEW AManaProducer(id, target,FinalOutput, input,doTap)); + }else{ + if (multi){ multi->Add(a); - }else{ + }else{ game->addObserver(a); - } - }else{ + } + } + }else{ OutputDebugString ("uh oh\n"); card->controller()->getManaPool()->add(output); delete output; - } + } result++; continue; }