Teaching AI proliferate and shocklands

Some minor changes, corrections to XLN and C17, changing name of game mode from horde to tribal wars
This commit is contained in:
Eduardo
2019-05-01 17:00:48 -05:00
parent f1a529576e
commit 06cb835a5b
5 changed files with 2349 additions and 2345 deletions

View File

@@ -1,5 +1,5 @@
include mtg.txt
name=Horde
name=Tribal Wars
unlock=prx_horde
[INIT]
mode=horde

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -710,6 +710,13 @@ int OrderedAIAction::getEfficiency()
{
if(ability->source->hasType(Subtypes::TYPE_PLANESWALKER))
efficiency += 40;
else if(ability->source->hasType(Subtypes::TYPE_LAND))
{ // probably a shockland, don't pay life if hand is empty
if (p->life<=2)
// check that's not a manland(like Celestial Colonnade)
if(efficiency < 50)
efficiency = 0;
}
}
SAFE_DELETE(transAbility);

View File

@@ -4549,6 +4549,8 @@ int AbilityFactory::abilityEfficiency(MTGAbility * a, Player * p, int mode, Targ
return BAKA_EFFECT_GOOD;
if (dynamic_cast<AARemoveAllCounter *> (a))
return BAKA_EFFECT_BAD;
if (dynamic_cast<AAProliferate *> (a))
return BAKA_EFFECT_GOOD;
// Equipment that gets immediately attached. Todo: check the abilities associated with Equip, to make sure they're good (for now it seems to be the majority of the cases)?
if (dynamic_cast<AEquip *> (a))