From 38e97aa79f62c3d38e947cc4f77687470fc04199 Mon Sep 17 00:00:00 2001 From: Anthony Calosa Date: Mon, 6 Mar 2017 17:52:44 +0800 Subject: [PATCH] fix etched affinity stalling the game add an alias for glimmervoid and removed the hold combo hint for glimmervoid, just tried etched affinity vs etched affinity on demo for 50 games... it doesn't stall anymore. it seems there's a conflict somewhere parsing hint combo? not really sure... also in momir the ai don't click choose a color command, noticed on lotus cobra so i changed the chooseacolor to abilty$! add{mana} ... --- projects/mtg/bin/Res/ai/baka/deck110.txt | 1 - projects/mtg/bin/Res/sets/primitives/mtg.txt | 3 ++- projects/mtg/src/AIPlayerBaka.cpp | 12 ++++++++++++ 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/projects/mtg/bin/Res/ai/baka/deck110.txt b/projects/mtg/bin/Res/ai/baka/deck110.txt index fee23320a..3894709c1 100644 --- a/projects/mtg/bin/Res/ai/baka/deck110.txt +++ b/projects/mtg/bin/Res/ai/baka/deck110.txt @@ -1,7 +1,6 @@ #NAME:Etched Affinity #DESC:Modern URB Aggro #HINT:dontattackwith(creature[power<=0]) -#HINT:combo hold(Glimmervoid|myhand)^cast(Glimmervoid|myhand)^restriction{type(land[fresh]|mybattlefield)~lessthan~1,type(artifact|mybattlefield)~morethan~0}^totalmananeeded({0}) #HINT:combo hold(Galvanic Blast|myhand)^cast(Galvanic Blast|myhand)^restriction{type(artifact|mybattlefield)~morethan~2,turn:3}^totalmananeeded({R}) #25 creatures diff --git a/projects/mtg/bin/Res/sets/primitives/mtg.txt b/projects/mtg/bin/Res/sets/primitives/mtg.txt index 4c6afb3e7..ed81266c8 100644 --- a/projects/mtg/bin/Res/sets/primitives/mtg.txt +++ b/projects/mtg/bin/Res/sets/primitives/mtg.txt @@ -46852,6 +46852,7 @@ subtype=Locus [/card] [card] name=Glimmervoid +alias=48132 auto={T}:add{W} auto={T}:add{U} auto={T}:add{B} @@ -68378,7 +68379,7 @@ type=Artifact [/card] [card] name=Lotus Cobra -auto=@movedTo(land|mybattlefield):chooseacolor add{chosencolor} chooseend +auto=@movedTo(land|mybattlefield):name(choose mana) ability$! choice add{G} _ choice add{R} _ choice add{U} _ choice add{B} _ choice add{W} !$ controller text=Landfall - Whenever a land enters the battlefield under your control, you may add one mana of any color to your mana pool. mana={1}{G} type=Creature diff --git a/projects/mtg/src/AIPlayerBaka.cpp b/projects/mtg/src/AIPlayerBaka.cpp index 61323df8c..e1288ca57 100644 --- a/projects/mtg/src/AIPlayerBaka.cpp +++ b/projects/mtg/src/AIPlayerBaka.cpp @@ -2542,6 +2542,10 @@ MTGCardInstance * AIPlayerBaka::FindCardToPlay(ManaCost * pMana, const char * ty if (card->hasType(Subtypes::TYPE_LEGENDARY) && game->inPlay->findByName(card->name)) continue; + //glimmervoid alias to avoid ai stalling the game as the hint combo is stuck + //next card to play was galvanic blast but on activate combo it clashes with glimmervoid... + if ((card->alias == 48132) && (card->controller()->game->inPlay->countByType("artifact") < 1)) + continue; if (card->has(Constants::TREASON) && observer->getCurrentGamePhase() != MTG_PHASE_FIRSTMAIN) continue; @@ -2693,6 +2697,10 @@ MTGCardInstance * AIPlayerBaka::FindCardToPlay(ManaCost * pMana, const char * ty if (card->hasType(Subtypes::TYPE_LEGENDARY) && game->inPlay->findByName(card->name)) continue; + //glimmervoid alias to avoid ai stalling the game as the hint combo is stuck + //next card to play was galvanic blast but on activate combo it clashes with glimmervoid... + if ((card->alias == 48132) && (card->controller()->game->inPlay->countByType("artifact") < 1)) + continue; if (card->has(Constants::TREASON) && observer->getCurrentGamePhase() != MTG_PHASE_FIRSTMAIN) continue; @@ -2843,6 +2851,10 @@ MTGCardInstance * AIPlayerBaka::FindCardToPlay(ManaCost * pMana, const char * ty if (card->hasType(Subtypes::TYPE_LEGENDARY) && game->inPlay->findByName(card->name)) continue; + //glimmervoid alias to avoid ai stalling the game as the hint combo is stuck + //next card to play was galvanic blast but on activate combo it clashes with glimmervoid... + if ((card->alias == 48132) && (card->controller()->game->inPlay->countByType("artifact") < 1)) + continue; if (card->has(Constants::TREASON) && observer->getCurrentGamePhase() != MTG_PHASE_FIRSTMAIN) continue;