Hearthranger - How to customize mulligan in vision a.i. ?
Open the ini file :
CustomConfig\deck_config.ini
In [CONFIGS] section, setup your deck's custom configuration directory, you need to create the directory under [CustomConfig] by yourself.
[CONFIGS]
MyDeckName = My_Deck_Config_Dir_Name
*No ; character before your deck name, ; is the character as comment line in .ini file.
In the directory of [My_Deck_Config_Dir_Name], create a json file named [Mulligan.json].
Simple samples:
{
"GameCardId":"Mulligan",
"ConfigComment":"This is mulligan rules file.",
"Mulligan":
{
"values":
[
{
"comment": "Patches the Pirate should be discarded",
"mulligan":"CFM_637",
"condition": "*",
"value":"discard",
}
,
{
"comment": "hold N'Zoth's First Mate (OG_312),Small-Time Buccaneer (CFM_325),Fiery War Axe (CS2_106),Frothing Berserker (EX1_604)",
"mulligan":"OG_312,CFM_325,CS2_106,EX1_604",
"condition": "*",
"value":"hold",
}
,
{
"comment": "Southsea Deckhand (CS2_146) + N'Zoth's First Mate (OG_312)",
"mulligan":"CS2_146 + OG_312",
"condition": "*",
"value":"hold",
}
,
{
"comment": "discard all cards not listed as hold",
"mulligan":"*",
"condition": "my_hero(count(),warrior) > 0",
"value":"discard",
}
],
},
}
Other samples:
{
"comment": "keep all drop 1",
"mulligan":"DROP1",
"condition": "*",
"value":"hold",
}
{
"comment": "keep all drop 1 + Frothing Berserker ",
"mulligan":"DROP1 + EX1_604",
"condition": "*",
"value":"hold",
}
{
"comment": "keep only one Corridor Creeper(LOOT_149) ",
"mulligan":"LOOT_149",
"condition": "*",
"value":"hold",
}
{
"comment": "keep only one Corridor Creeper(LOOT_149), and two if lucky",
"mulligan":"LOOT_149, LOOT_149+ LOOT_149", //works in v.10.4.5.0 or higher version
"condition": "*",
"value":"hold",
}
sure you can use DROP2, DROP3,DROP4 ....
Advanced samples:
{
"comment": "keep all drop 3 with coin",
"mulligan":"DROP3",
"condition": "coin",
"value":"hold",
}
{
"comment": "discard all drop 3 without coin",
"mulligan":"DROP3",
"condition": "nocoin",
"value":"discard",
}
{
"comment": "if bot has coin, keep Twilight Guardian(AT_017) when opponent is warrior",
"mulligan":"AT_017",
"condition": "coin AND opp_hero(count(),warrior=true) > 0",
"value":"hold",
}
{
"comment": "if bot has coin, keep Twilight Guardian(AT_017) when opponent is warrior or rogue or paladin",
"mulligan":"AT_017",
"condition": "coin AND opp_hero(count(), hero_class=warrior | rogue | paladin ) > 0",
"value":"hold",
}
*keyword 'hero_class' is available in v.9.6.0.0 or higher.
The condition of last sample can be also written as
{
"comment": "if bot has coin, keep Twilight Guardian(AT_017) when opponent is warrior",
"mulligan":"AT_017",
"condition": "my_hand(count()) == 4 AND opp_hero(count(),warrior=true) > 0",
"value":"hold",
}
my_hand(count()) == 4 means bot has 4 cards when started, so it must have coin.
To understand condition and value, please read:
Hearthranger - How to understand json config ?
* hold rule has higher priority than discard, in the following sample, ' Patches the Pirate' will be hold, since all DROP1 is set to be hold.
{
"comment": "Patches the Pirate should be discarded",
"mulligan":"CFM_637",
"condition": "*",
"value":"discard",
}
,
{
"comment": "Hold all drop 1",
"mulligan":"DROP1",
"condition": "*",
"value":"hold",
}
How to test it?
After bot plays a game, this game's review file (*.rew) is automatically generated.
Click button to open
review window.
Ensure 3 is correctly selected.
Then click 4 button, you'll see custom mulligan results:
After you edited [Mulligan.json] with third-party editor (notepad etc), click 4 to re-test it.