Laurent - Some cards addition (TMP -> serene offering alias of divine offering from LEG also in MRD)

MRD added Seed of innocence
INV added aura and artifact mutation (but strange reaction if you bury target from opponent)... works anyway... test it and you will understand... ;)
This commit is contained in:
wagic.laurent
2009-05-22 14:41:51 +00:00
parent fe64587bb3
commit 52ea815193
7 changed files with 80 additions and 48 deletions
+32
View File
@@ -1710,6 +1710,23 @@ void AbilityFactory::addAbilities(int _id, Spell * spell){
break;
}
// --- addon Mirage ---
case 3410: //Seed of Innocence
{
GameObserver * game = GameObserver::GetInstance();
for (int i = 0; i < 2 ; i++){
for (int j = 0; j < game->players[i]->game->inPlay->nb_cards; j++){
MTGCardInstance * current = game->players[i]->game->inPlay->cards[j];
if (current->hasType("Artifact")){
game->players[i]->game->putInGraveyard(current);
current->controller()->life-= current->getManaCost()->getConvertedCost();
}
}
}
break;
}
//-- addon 10E---
case 129523: //Demon's Horn
{
@@ -1753,12 +1770,27 @@ void AbilityFactory::addAbilities(int _id, Spell * spell){
game->currentlyActing()->life+=damage_life;
break;
}
// --- addon Invasion---
case 23195: //Artifact Mutation (works fine but display is strange if you bury a target from opponent, need to wait your turn to have the token put in play)
{
card->target->controller()->game->putInGraveyard(card->target);
int x = card->target->getManaCost()->getConvertedCost();
ATokenCreator * tok = NEW ATokenCreator(id,card,NEW ManaCost(),"Saproling token","creature",1,1,"green",0);
for (int i=0; i < x; i++){
tok->resolve();
}
delete tok;
break;
}
default:
break;
}
/* Erwan - 2008/11/13: We want to get rid of these basicAbility things.
* basicAbilities themselves are alright, but creating new object depending on them is dangerous
* The main reason is that classes that add an ability to a card do NOT create these objects, and therefore do NOT