Dominion Strategy Forum

Please login or register.

Login with username, password and session length
Pages: 1 2 [3] 4  All

Author Topic: Project: Optimizing Big Money X  (Read 39417 times)

0 Members and 1 Guest are viewing this topic.

DStu

  • Margrave
  • *****
  • Offline Offline
  • Posts: 2627
  • Respect: +1490
    • View Profile
Re: Project: Optimizing Big Money X
« Reply #50 on: January 20, 2012, 03:43:40 am »
0

Small improvement for Familiar, not at all fitting the theme "optimize BM", but however
Code: [Select]
<player name="Familiar_impr"
 author="Geronimoo"
 description="Familiar is often one of the defining cards on a board.">
 <type name="Attacking"/>
 <type name="Province"/>
 <type name="SingleCard"/>
 <type name="UserCreated"/>
 <type name="TwoPlayer"/>
 <type name="BigMoney"/>
 <type name="Bot"/>
   <buy name="Province"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
   </buy>
   <buy name="Gold"/>
   <buy name="Familiar">
      <condition>
         <left type="countCardsInDeck" attribute="Familiar"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="3.0"/>
      </condition>
      <condition>
         <left type="countCardsInSupply" attribute="Curse"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
   </buy>
   <buy name="Potion">
      <condition>
         <left type="countCardsInDeck" attribute="Potion"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="1.0"/>
      </condition>
   </buy>
   <buy name="Silver"/>
</player>
Logged

Fabian

  • 2012 Swedish Champion
  • *
  • Offline Offline
  • Posts: 666
  • Respect: +542
    • View Profile
Re: Project: Optimizing Big Money X
« Reply #51 on: January 20, 2012, 07:33:30 am »
0

WW, Witch bot is posted twice.
Logged

WanderingWinder

  • Adventurer
  • ******
  • Offline Offline
  • Posts: 5275
  • ...doesn't really matter to me
  • Respect: +4381
    • View Profile
    • WanderingWinder YouTube Page
Re: Project: Optimizing Big Money X
« Reply #52 on: January 20, 2012, 08:55:49 am »
0

WW, Witch bot is posted twice.
Thanks for the heads-up. Now fixed

WanderingWinder

  • Adventurer
  • ******
  • Offline Offline
  • Posts: 5275
  • ...doesn't really matter to me
  • Respect: +4381
    • View Profile
    • WanderingWinder YouTube Page
Re: Project: Optimizing Big Money X
« Reply #53 on: January 21, 2012, 09:31:41 am »
0

Small improvement for Mountebank:
Code: [Select]
<player name="Mountebank by WW"
 author="Geronimoo"
 description="Mountebank might be the strongest attack. It's a better buy than Gold (so it will be bought with $6)">
 <type name="UserCreated"/>
 <type name="Competitive"/>
 <type name="Province"/>
 <type name="BigMoney"/>
 <type name="Bot"/>
 <type name="Attacking"/>
 <type name="SingleCard"/>
 <type name="TwoPlayer"/>
   <buy name="Province">
      <condition>
         <left type="getTotalMoney"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="22.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="gainsNeededToEndGame"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="gainsNeededToEndGame"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="3.0"/>
      </condition>
   </buy>
   <buy name="Mountebank">
      <condition>
         <left type="countCardsInDeck" attribute="Mountebank"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="1.0"/>
      </condition>
   </buy>
   <buy name="Gold"/>
   <buy name="Duchy">
      <condition>
         <left type="gainsNeededToEndGame"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
   </buy>
   <buy name="Mountebank">
      <condition>
         <left type="countCardsInDeck" attribute="Mountebank"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="gainsNeededToEndGame"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="6.0"/>
      </condition>
   </buy>
   <buy name="Mountebank">
      <condition>
         <left type="countCardsInDeck" attribute="Mountebank"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="3.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="gainsNeededToEndGame"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="7.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="gainsNeededToEndGame"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
   </buy>
   <buy name="Silver"/>
</player>

WanderingWinder

  • Adventurer
  • ******
  • Offline Offline
  • Posts: 5275
  • ...doesn't really matter to me
  • Respect: +4381
    • View Profile
    • WanderingWinder YouTube Page
Re: Project: Optimizing Big Money X
« Reply #54 on: January 22, 2012, 01:26:45 pm »
0

Small improvement for Smithy:
Code: [Select]
<player name="SmithyWW"
 author="HiveMindEmulator"
 description="The optimized strategy that buys no other actions.">
 <type name="TwoPlayer"/>
 <type name="SingleCard"/>
 <type name="Province"/>
 <type name="Optimized"/>
 <type name="UserCreated"/>
 <type name="Bot"/>
 <type name="BigMoney"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="equalTo" />
         <right type="constant" attribute="2.0"/>
      </condition>
      <condition>
         <left type="countVP"/>
         <operator type="smallerThan" />
         <right type="countMAXOpponentVP"/>
      </condition>
      <condition>
         <left type="countVP"/>
         <operator type="greaterThan" />
         <right type="countMAXOpponentVP"/>
         <extra_operation type="minus" attribute="3.0" />
      </condition>
   </buy>
   <buy name="Province">
      <condition>
         <left type="getTotalMoney"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="15.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
   </buy>
   <buy name="Gold"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
   </buy>
   <buy name="Smithy">
      <condition>
         <left type="countCardsInDeck" attribute="Smithy"/>
         <operator type="equalTo" />
         <right type="constant" attribute="0.0"/>
      </condition>
   </buy>
   <buy name="Smithy">
      <condition>
         <left type="countCardsInDeck" attribute="Smithy"/>
         <operator type="equalTo" />
         <right type="constant" attribute="1.0"/>
      </condition>
      <condition>
         <left type="countCardTypeInDeck" attribute="Treasure"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="11.0"/>
      </condition>
   </buy>
   <buy name="Smithy">
      <condition>
         <left type="countCardsInDeck" attribute="Smithy"/>
         <operator type="equalTo" />
         <right type="constant" attribute="2.0"/>
      </condition>
      <condition>
         <left type="countCardTypeInDeck" attribute="Treasure"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="23.0"/>
      </condition>
   </buy>
   <buy name="Silver"/>
   <buy name="Estate">
      <condition>
         <left type="gainsNeededToEndGame"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
   </buy>
</player>

And a merchant ship bot:
Code: [Select]
<player name="Merchant Ship WW"
 author="WanderingWinder"
 description="The optimized Merchant Ship bot which buys no other actions">
 <type name="TwoPlayer"/>
 <type name="SingleCard"/>
 <type name="Province"/>
 <type name="Optimized"/>
 <type name="UserCreated"/>
 <type name="Bot"/>
 <type name="BigMoney"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="equalTo" />
         <right type="constant" attribute="2.0"/>
      </condition>
      <condition>
         <left type="countVP"/>
         <operator type="smallerThan" />
         <right type="countMAXOpponentVP"/>
      </condition>
      <condition>
         <left type="countVP"/>
         <operator type="greaterThan" />
         <right type="countMAXOpponentVP"/>
         <extra_operation type="minus" attribute="3.0" />
      </condition>
   </buy>
   <buy name="Province">
      <condition>
         <left type="getTotalMoney"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="13.0"/>
      </condition>
   </buy>
   <buy name="Province">
      <condition>
         <left type="countCardsInDeck" attribute="Merchant_Ship"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="1.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
   </buy>
   <buy name="Merchant_Ship">
      <condition>
         <left type="countCardsInDeck" attribute="Merchant_Ship"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="1.0"/>
      </condition>
   </buy>
   <buy name="Gold"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
   </buy>
   <buy name="Merchant_Ship">
      <condition>
         <left type="countCardsInDeck" attribute="Merchant_Ship"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="6.0"/>
      </condition>
   </buy>
   <buy name="Merchant_Ship">
      <condition>
         <left type="countCardsInDeck" attribute="Merchant_Ship"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="3.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="6.0"/>
      </condition>
   </buy>
   <buy name="Silver"/>
   <buy name="Estate">
      <condition>
         <left type="gainsNeededToEndGame"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
   </buy>
</player>

WanderingWinder

  • Adventurer
  • ******
  • Offline Offline
  • Posts: 5275
  • ...doesn't really matter to me
  • Respect: +4381
    • View Profile
    • WanderingWinder YouTube Page
Re: Project: Optimizing Big Money X
« Reply #55 on: January 27, 2012, 07:05:07 pm »
0

Mandarin. Wins 57-33 against BMU, ahead of such favourites as Lab(!)
Code: [Select]
<player name="Mandarin"
 author="WanderingWinder"
 description="The optimized Mandarin bot that buys no other actions.">
 <type name="Province"/>
 <type name="UserCreated"/>
 <type name="TwoPlayer"/>
 <type name="Bot"/>
 <type name="Optimized"/>
 <type name="BigMoney"/>
 <type name="SingleCard"/>
   <buy name="Province">
      <condition>
         <left type="getTotalMoney"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="15.0"/>
      </condition>
   </buy>
   <buy name="Mandarin">
      <condition>
         <left type="countCardsInPlay" attribute="Copper"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
      <condition>
         <left type="countCardsInSupply" attribute="Duchy"/>
         <operator type="equalTo" />
         <right type="constant" attribute="0.0"/>
      </condition>
      <condition>
         <left type="countVP"/>
         <operator type="greaterThan" />
         <right type="countMAXOpponentVP"/>
         <extra_operation type="minus" attribute="4.0" />
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
   </buy>
   <buy name="Gold"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="6.0"/>
      </condition>
   </buy>
   <buy name="Mandarin">
      <condition>
         <left type="countCardsInDeck" attribute="Mandarin"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
   </buy>
   <buy name="Mandarin">
      <condition>
         <left type="countCardsInPlay" attribute="Copper"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
      <condition>
         <left type="countCardsInDeck" attribute="Mandarin"/>
         <operator type="smallerThan" />
         <right type="countAllCardsInDeck"/>
         <extra_operation type="divideBy" attribute="6.0" />
      </condition>
   </buy>
   <buy name="Silver"/>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
   </buy>
</player>

DG

  • Governor
  • *****
  • Offline Offline
  • Posts: 4074
  • Respect: +2624
    • View Profile
Re: Project: Optimizing Big Money X
« Reply #56 on: January 27, 2012, 09:15:35 pm »
0

Are you sure the Mandarin needs to be that complicated? This just takes a little more treasure before greening and never buys more mandarins if there is more than one copper in play. I'm actually surprised that it beats big money on a 4/3 split.

Code: [Select]
<player name="Mandarin (DG)"
 author="DG"
 description="Fairly simple Mandarin deck">
 <type name="Optimized"/>
 <type name="Province"/>
 <type name="BigMoney"/>
 <type name="TwoPlayer"/>
 <type name="SingleCard"/>
 <type name="Bot"/>
 <type name="UserCreated"/>
   <buy name="Province">
      <condition>
         <left type="getTotalMoney"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="19.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
   </buy>
   <buy name="Gold"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
   </buy>
   <buy name="Mandarin">
      <condition>
         <left type="countCardsInDeck" attribute="Mandarin"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="1.0"/>
      </condition>
   </buy>
   <buy name="Mandarin">
      <condition>
         <left type="countCardsInDeck" attribute="Mandarin"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
      <condition>
         <left type="countCardsInPlay" attribute="Copper"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
   </buy>
   <buy name="Silver"/>
</player>
Logged

WanderingWinder

  • Adventurer
  • ******
  • Offline Offline
  • Posts: 5275
  • ...doesn't really matter to me
  • Respect: +4381
    • View Profile
    • WanderingWinder YouTube Page
Re: Project: Optimizing Big Money X
« Reply #57 on: January 28, 2012, 03:09:01 pm »
0

Are you sure the Mandarin needs to be that complicated? This just takes a little more treasure before greening and never buys more mandarins if there is more than one copper in play. I'm actually surprised that it beats big money on a 4/3 split.

Code: [Select]
<player name="Mandarin (DG)"
 author="DG"
 description="Fairly simple Mandarin deck">
 <type name="Optimized"/>
 <type name="Province"/>
 <type name="BigMoney"/>
 <type name="TwoPlayer"/>
 <type name="SingleCard"/>
 <type name="Bot"/>
 <type name="UserCreated"/>
   <buy name="Province">
      <condition>
         <left type="getTotalMoney"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="19.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
   </buy>
   <buy name="Gold"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
   </buy>
   <buy name="Mandarin">
      <condition>
         <left type="countCardsInDeck" attribute="Mandarin"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="1.0"/>
      </condition>
   </buy>
   <buy name="Mandarin">
      <condition>
         <left type="countCardsInDeck" attribute="Mandarin"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
      <condition>
         <left type="countCardsInPlay" attribute="Copper"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
   </buy>
   <buy name="Silver"/>
</player>
No, you're right. The 'complicated' stuff at the top has to help, but won't come up very often at all. Putting it out in more situations than 'no duchies, not too far behind' will probably help more, but it's a bit of work identifying those situations. But buying Mandarins slightly more aggressively than yours does help. Here's a non-optimized but improved version:

Code: [Select]
<player name="Mandarin"
 author="WanderingWinder"
 description="The optimized Mandarin bot that buys no other actions.">
 <type name="Province"/>
 <type name="Optimized"/>
 <type name="BigMoney"/>
 <type name="TwoPlayer"/>
 <type name="SingleCard"/>
 <type name="Bot"/>
 <type name="UserCreated"/>
   <buy name="Province">
      <condition>
         <left type="getTotalMoney"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="18.0"/>
      </condition>
   </buy>
   <buy name="Mandarin">
      <condition>
         <left type="countCardsInPlay" attribute="Copper"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
      <condition>
         <left type="countCardsInSupply" attribute="Duchy"/>
         <operator type="equalTo" />
         <right type="constant" attribute="0.0"/>
      </condition>
      <condition>
         <left type="countVP"/>
         <operator type="greaterThan" />
         <right type="countMAXOpponentVP"/>
         <extra_operation type="minus" attribute="3.0" />
      </condition>
      <condition>
         <left type="countCardsInPlay" attribute="Gold"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="0.0"/>
      </condition>
   </buy>
   <buy name="Mandarin">
      <condition>
         <left type="countCardsInPlay" attribute="Copper"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="3.0"/>
      </condition>
      <condition>
         <left type="countCardsInSupply" attribute="Duchy"/>
         <operator type="equalTo" />
         <right type="constant" attribute="0.0"/>
      </condition>
      <condition>
         <left type="countVP"/>
         <operator type="greaterThan" />
         <right type="countMAXOpponentVP"/>
         <extra_operation type="minus" attribute="3.0" />
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
   </buy>
   <buy name="Gold"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="6.0"/>
      </condition>
   </buy>
   <buy name="Mandarin">
      <condition>
         <left type="countCardsInDeck" attribute="Mandarin"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
      <condition>
         <left type="countTurns"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
   </buy>
   <buy name="Mandarin">
      <condition>
         <left type="countCardsInPlay" attribute="Copper"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="3.0"/>
      </condition>
      <condition>
         <left type="countCardsInDeck" attribute="Mandarin"/>
         <operator type="smallerThan" />
         <right type="countAllCardsInDeck"/>
         <extra_operation type="divideBy" attribute="7.0" />
      </condition>
   </buy>
   <buy name="Mandarin">
      <condition>
         <left type="countCardsInPlay" attribute="Copper"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
      <condition>
         <left type="countCardsInDeck" attribute="Mandarin"/>
         <operator type="smallerThan" />
         <right type="countAllCardsInDeck"/>
         <extra_operation type="divideBy" attribute="6.0" />
      </condition>
   </buy>
   <buy name="Mandarin">
      <condition>
         <left type="countCardsInPlay" attribute="Copper"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
      <condition>
         <left type="countCardsInDeck" attribute="Mandarin"/>
         <operator type="smallerThan" />
         <right type="countAllCardsInDeck"/>
         <extra_operation type="divideBy" attribute="9.0" />
      </condition>
   </buy>
   <buy name="Silver"/>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
   </buy>
</player>

DG

  • Governor
  • *****
  • Offline Offline
  • Posts: 4074
  • Respect: +2624
    • View Profile
Re: Project: Optimizing Big Money X
« Reply #58 on: January 28, 2012, 08:02:09 pm »
0

Your version was still weaker than mine on a 5/2 opening though. Change your script to buy one mandarin on turns 1-2 instead of two mandarins on turns 1-3 and it does become the stronger one.

You might want to consider extra conditions where there's only one province in the supply or there's only one duchy in the supply, if you want to tease out those exact endgame treasure strategies.
« Last Edit: January 28, 2012, 08:12:04 pm by DG »
Logged

WanderingWinder

  • Adventurer
  • ******
  • Offline Offline
  • Posts: 5275
  • ...doesn't really matter to me
  • Respect: +4381
    • View Profile
    • WanderingWinder YouTube Page
Re: Project: Optimizing Big Money X
« Reply #59 on: February 06, 2012, 12:19:03 pm »
0

Significant improvement on the Hoard bot:
Code: [Select]
<player name="Hoard2"
 author="WanderingWinder"
 description="The optimized Hoard strategy that buys no actions.">
 <type name="UserCreated"/>
 <type name="Bot"/>
 <type name="Optimized"/>
 <type name="SingleCard"/>
 <type name="Province"/>
 <type name="TwoPlayer"/>
 <type name="BigMoney"/>
   <buy name="Province">
      <condition>
         <left type="getTotalMoney"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="19.0"/>
      </condition>
   </buy>
   <buy name="Province">
      <condition>
         <left type="countCardsInPlay" attribute="Hoard"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="0.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInPlay" attribute="Hoard"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="0.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="countCardsInPlay" attribute="Hoard"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="1.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
   </buy>
   <buy name="Hoard">
      <condition>
         <left type="getTotalMoney"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="12.0"/>
      </condition>
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="greaterOrEqualThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
   </buy>
   <buy name="Gold"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="7.0"/>
      </condition>
   </buy>
   <buy name="Silver"/>
</player>

HiveMindEmulator

  • Mountebank
  • *****
  • Offline Offline
  • Posts: 2222
  • Respect: +2118
    • View Profile
Re: Project: Optimizing Big Money X
« Reply #60 on: February 06, 2012, 04:47:58 pm »
0

^You can do a bit better if you add
Code: [Select]
   <buy name="Estate">
      <condition>
         <left type="countCardsInPlay" attribute="Hoard"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="0.0"/>
      </condition>
above silver.
Logged

DG

  • Governor
  • *****
  • Offline Offline
  • Posts: 4074
  • Respect: +2624
    • View Profile
Re: Project: Optimizing Big Money X
« Reply #61 on: February 06, 2012, 07:06:56 pm »
0

This is basically the WW hoard bot with a few adjustments - Extra condition to cover edge cases buying duchies and provinces based on number of hoards in the deck. Buys estates earlier. Includes the line suggested by HiveMindEmulator.

Code: [Select]
<player name="Hoard optimized "
 author="DG"
 description="Small tinkering to the optimzed script created by WanderingWinder">
 <type name="TwoPlayer"/>
 <type name="BigMoney"/>
 <type name="UserCreated"/>
 <type name="Province"/>
 <type name="Bot"/>
 <type name="SingleCard"/>
 <type name="Optimized"/>
   <buy name="Province">
      <condition>
         <left type="getTotalMoney"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="19.0"/>
      </condition>
   </buy>
   <buy name="Province">
      <condition>
         <left type="countCardsInPlay" attribute="Hoard"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="0.0"/>
      </condition>
   </buy>
   <buy name="Province">
      <condition>
         <left type="countCardsInDeck" attribute="Hoard"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="1.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInPlay" attribute="Hoard"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="0.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInDeck" attribute="Hoard"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="countCardsInPlay" attribute="Hoard"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="1.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
   </buy>
   <buy name="Hoard">
      <condition>
         <left type="getTotalMoney"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="12.0"/>
      </condition>
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="greaterOrEqualThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
   </buy>
   <buy name="Gold"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="7.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="countCardsInPlay" attribute="Hoard"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="0.0"/>
      </condition>
   </buy>
   <buy name="Silver"/>
</player>
Logged

Loschmidt

  • Golem
  • ****
  • Offline Offline
  • Posts: 180
  • Respect: +61
    • View Profile
Re: Project: Optimizing Big Money X
« Reply #62 on: February 06, 2012, 09:07:57 pm »
0

Hey guys. I've recently got on the simulating bandwagon and i'm already addicted. And I think this is a brilliant idea. So here is my first contribution.

Code: [Select]
<player name="Workshop"
 author="Loschmidt"
 description="Optimised workshop bot.">
 <type name="UserCreated"/>
 <type name="Province"/>
 <type name="BigMoney"/>
 <type name="Bot"/>
 <type name="Optimized"/>
 <type name="TwoPlayer"/>
 <type name="SingleCard"/>
   <buy name="Gold">
      <condition>
         <left type="getTotalMoney"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="17.0"/>
      </condition>
   </buy>
   <buy name="Province"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="3.0"/>
      </condition>
   </buy>
   <buy name="Gold"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="7.0"/>
      </condition>
   </buy>
   <buy name="Workshop">
      <condition>
         <left type="countCardsInDeck" attribute="Workshop"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="1.0"/>
      </condition>
   </buy>
   <buy name="Silver"/>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="7.0"/>
      </condition>
   </buy>
</player>

Its the best I can get out of a Workshop bot. Its based on WW BMU bot, the only differences are the Workshop and it starts to green a fraction earlier. Its losing to BMU at about 43%, if someone can make any improvements i'd like to know :D
Logged

WanderingWinder

  • Adventurer
  • ******
  • Offline Offline
  • Posts: 5275
  • ...doesn't really matter to me
  • Respect: +4381
    • View Profile
    • WanderingWinder YouTube Page
Re: Project: Optimizing Big Money X
« Reply #63 on: February 06, 2012, 09:20:56 pm »
0

Hey guys. I've recently got on the simulating bandwagon and i'm already addicted. And I think this is a brilliant idea. So here is my first contribution.

Code: [Select]
<player name="Workshop"
 author="Loschmidt"
 description="Optimised workshop bot.">
 <type name="UserCreated"/>
 <type name="Province"/>
 <type name="BigMoney"/>
 <type name="Bot"/>
 <type name="Optimized"/>
 <type name="TwoPlayer"/>
 <type name="SingleCard"/>
   <buy name="Gold">
      <condition>
         <left type="getTotalMoney"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="17.0"/>
      </condition>
   </buy>
   <buy name="Province"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="3.0"/>
      </condition>
   </buy>
   <buy name="Gold"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="7.0"/>
      </condition>
   </buy>
   <buy name="Workshop">
      <condition>
         <left type="countCardsInDeck" attribute="Workshop"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="1.0"/>
      </condition>
   </buy>
   <buy name="Silver"/>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="7.0"/>
      </condition>
   </buy>
</player>

Its the best I can get out of a Workshop bot. Its based on WW BMU bot, the only differences are the Workshop and it starts to green a fraction earlier. Its losing to BMU at about 43%, if someone can make any improvements i'd like to know :D
Here's an improvement: don't buy workshop :)
No, seriously, there's no point if there isn't a better target than silver.

Loschmidt

  • Golem
  • ****
  • Offline Offline
  • Posts: 180
  • Respect: +61
    • View Profile
Re: Project: Optimizing Big Money X
« Reply #64 on: February 06, 2012, 09:57:36 pm »
0

Quote
Here's an improvement: don't buy workshop :)
No, seriously, there's no point if there isn't a better target than silver.

Well yeah, I get that. I'm not seriously proposing this as a strategy :P I just thought it would be good to be thorough have every single card bot coded. And if you were working alphabetically down i'm working alphabetically up.

Speaking of that here's woodcutter. A pretty straightforward one. Almost exactly 50%

Code: [Select]
<player name="Woodcutter"
 author="Loschmidt"
 description="Woodcutter optimised">
 <type name="UserCreated"/>
 <type name="Province"/>
 <type name="BigMoney"/>
 <type name="Bot"/>
 <type name="Optimized"/>
 <type name="TwoPlayer"/>
 <type name="SingleCard"/>
   <buy name="Province">
      <condition>
         <left type="getTotalMoney"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="18.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="3.0"/>
      </condition>
   </buy>
   <buy name="Gold"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
   </buy>
   <buy name="Woodcutter">
      <condition>
         <left type="countCardsInDeck" attribute="Woodcutter"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="1.0"/>
      </condition>
   </buy>
   <buy name="Silver"/>
   <buy name="Estate">
      <condition>
         <left type="countTurns"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="17.0"/>
      </condition>
   </buy>
</player>
Logged

Loschmidt

  • Golem
  • ****
  • Offline Offline
  • Posts: 180
  • Respect: +61
    • View Profile
Re: Project: Optimizing Big Money X
« Reply #65 on: February 06, 2012, 10:16:57 pm »
0

Library

Code: [Select]
<player name="Library"
 author="Loschmidt"
 description="Library only bot optimised">
 <type name="UserCreated"/>
 <type name="Province"/>
 <type name="BigMoney"/>
 <type name="Bot"/>
 <type name="Optimized"/>
 <type name="TwoPlayer"/>
 <type name="SingleCard"/>
   <buy name="Province">
      <condition>
         <left type="getTotalMoney"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="16.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
   </buy>
   <buy name="Library">
      <condition>
         <left type="countCardsInDeck" attribute="Library"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="1.0"/>
      </condition>
      <condition>
         <left type="countCardsInDeck" attribute="Gold"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="0.0"/>
      </condition>
   </buy>
   <buy name="Gold"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="6.0"/>
      </condition>
   </buy>
   <buy name="Library">
      <condition>
         <left type="countCardsInDeck" attribute="Library"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
   </buy>
   <buy name="Silver"/>
</player>
Logged

WanderingWinder

  • Adventurer
  • ******
  • Offline Offline
  • Posts: 5275
  • ...doesn't really matter to me
  • Respect: +4381
    • View Profile
    • WanderingWinder YouTube Page
Re: Project: Optimizing Big Money X
« Reply #66 on: February 06, 2012, 10:52:34 pm »
+1

Quote
Here's an improvement: don't buy workshop :)
No, seriously, there's no point if there isn't a better target than silver.

Well yeah, I get that. I'm not seriously proposing this as a strategy :P I just thought it would be good to be thorough have every single card bot coded. And if you were working alphabetically down i'm working alphabetically up.

Speaking of that here's woodcutter. A pretty straightforward one. Almost exactly 50%

Code: [Select]
<player name="Woodcutter"
 author="Loschmidt"
 description="Woodcutter optimised">
 <type name="UserCreated"/>
 <type name="Province"/>
 <type name="BigMoney"/>
 <type name="Bot"/>
 <type name="Optimized"/>
 <type name="TwoPlayer"/>
 <type name="SingleCard"/>
   <buy name="Province">
      <condition>
         <left type="getTotalMoney"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="18.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="3.0"/>
      </condition>
   </buy>
   <buy name="Gold"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
   </buy>
   <buy name="Woodcutter">
      <condition>
         <left type="countCardsInDeck" attribute="Woodcutter"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="1.0"/>
      </condition>
   </buy>
   <buy name="Silver"/>
   <buy name="Estate">
      <condition>
         <left type="countTurns"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="17.0"/>
      </condition>
   </buy>
</player>
The point is to have the optimal one-card strategy for each card. For a LOT of cards, that's BMU. Of course, many of those cards are really good, just you need other cards with them.

HiveMindEmulator

  • Mountebank
  • *****
  • Offline Offline
  • Posts: 2222
  • Respect: +2118
    • View Profile
Re: Project: Optimizing Big Money X
« Reply #67 on: February 07, 2012, 01:14:56 am »
0

This is basically the WW hoard bot with a few adjustments - Extra condition to cover edge cases buying duchies and provinces based on number of hoards in the deck. Buys estates earlier. Includes the line suggested by HiveMindEmulator.
This is really interesting. It's kind of surprising how early you want to be in full-on green mode, though I guess it makes sense given that your deck can produce tons of Gold.
Logged

DG

  • Governor
  • *****
  • Offline Offline
  • Posts: 4074
  • Respect: +2624
    • View Profile
Re: Project: Optimizing Big Money X
« Reply #68 on: February 07, 2012, 09:01:36 am »
0

Quote
Speaking of that here's woodcutter. A pretty straightforward one. Almost exactly 50%

If you use the big money scripts with turn based decisions based on the shuffles (turns 6, 9, 12), then the script can make use of the extra buy earlier. After a reshuffle on turn 12 it would buy a duchy and estate for 7 on turn 13 with a woodcutter based on the premise that those cards are unlikely to be drawn again. If you apply the PPR to both decks as well then the woodcutter gains another small advantage to push the win rate to 51-41. However both the PPR and turns rule are probably best left out of a multi purpose baseline script.

The extra buy is only useful if you plan to make use of it.
Logged

blueblimp

  • Margrave
  • *****
  • Offline Offline
  • Posts: 2849
  • Respect: +1559
    • View Profile
Re: Project: Optimizing Big Money X
« Reply #69 on: February 16, 2012, 11:49:22 pm »
0

Improved scripts for witch and Ill-Gotten Gains:
Code: [Select]
<player name="Witch by WW"
 author="WanderingWinder"
 description="Witch is probably the strongest attack card in the game.">
 <type name="UserCreated"/>
 <type name="Competitive"/>
 <type name="Province"/>
 <type name="BigMoney"/>
 <type name="Bot"/>
 <type name="Attacking"/>
 <type name="SingleCard"/>
 <type name="TwoPlayer"/>
   <buy name="Province">
      <condition>
         <left type="getTotalMoney"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="20.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="getTotalMoney"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="32.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="gainsNeededToEndGame"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="3.0"/>
      </condition>
   </buy>
   <buy name="Witch">
      <condition>
         <left type="countCardsInDeck" attribute="Witch"/>
         <operator type="equalTo" />
         <right type="constant" attribute="0.0"/>
      </condition>
   </buy>
   <buy name="Gold"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="getTotalMoney"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="30.0"/>
      </condition>
   </buy>
   <buy name="Estate">
      <condition>
         <left type="gainsNeededToEndGame"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
   </buy>
   <buy name="Witch">
      <condition>
         <left type="countCardsInSupply" attribute="Witch"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="6.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="getTotalMoney"/>
         <operator type="greaterThan" />
         <right type="constant" attribute="26.0"/>
      </condition>
   </buy>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Province"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="6.0"/>
      </condition>
   </buy>
   <buy name="Silver"/>
   <buy name="Estate">
      <condition>
         <left type="gainsNeededToEndGame"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
   </buy>
   <buy name="Copper">
      <condition>
         <left type="countCardsInSupply" attribute="Curse"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="1.0"/>
      </condition>
   </buy>
</player>

Code: [Select]
<player name="IGG Rush"
 author="WanderingWinder"
 description="Get all the Ill-Gotten Gains and Duchies to empty 3 piles.">
 <type name="UserCreated"/>
 <type name="Competitive"/>
 <type name="Province"/>
 <type name="BigMoney"/>
 <type name="Bot"/>
 <type name="SingleCard"/>
 <type name="TwoPlayer"/>
   <buy name="Province"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Curse"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
   </buy>
   <buy name="Ill_Gotten_Gains"/>
   <buy name="Duchy"/>
   <buy name="Estate">
      <condition>
         <left type="gainsNeededToEndGame"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
   </buy>
   <buy name="Silver"/>
   <buy name="Estate">
      <condition>
         <left type="gainsNeededToEndGame"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
   </buy>
   <buy name="Copper">
      <condition>
         <left type="gainsNeededToEndGame"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="4.0"/>
      </condition>
   </buy>
</player>


I've improved and simplified the IGG bot. It gets a a 57.7/38.7 win-rate vs WW's bot. Some notes first.

I tried deleting the copper-buy-rule and found that it didn't make the bot any worse. Stats (error intervals are with 99% confidence):
  Win: 47.4% +/- 0.4%
  Loss: 47.1% +/- 0.4%
  Tie: 5.4% +/- 0.2%
So it's definitely not worse, and maybe a tiny hair better.

I tried removing the after-silver estate rule, but that made the bot a lot worse. However, moving that estate rule above silver (and deleting the estate rule that was already there and is now redundant) makes the bot significantly better:
  Win: 52.7% +/- 0.4%
  Loss: 42.8% +/- 0.4%
  Tie: 4.5% +/- 0.2%
That's a pretty big difference!

I tried deleting the early-duchy rule, but doing that brings the winrate back down a bit:
  Win: 50.4% +/- 0.4%
  Loss: 44.9% +/- 0.4%
  Tie: 4.7% +/- 0.2%
I tweaked this around a bit and found though that "curse <= 1" performs best, giving a 49.971/45.75 advantage against "curse <= 2".

Finally, I set about tweaking when to start buying estates. Originally this was "#gains <= 4". I found that against this rule, I could get a 51.814/44.415 advantage with "#gains <= 6", and against WW's bot it gets 56.573/39.726, quite good. Unfortunately this causes a slight decrease in performance against BMU, because BMU is going for different piles. So I re-tweaked to "#duchies <= 5" (which should be roughly equivalent in the mirror if early duchies are taken with "curse <= 1"), and this restored performance against BMU and actually does better in the mirror for some reason.

Final bot:
Code: [Select]
<player name="IGG Rush Final"
 author="blueblimp"
 description="Get all the Ill-Gotten Gains and Duchies to empty 3 piles.">
 <type name="BigMoney"/>
 <type name="UserCreated"/>
 <type name="SingleCard"/>
 <type name="TwoPlayer"/>
 <type name="Province"/>
 <type name="Bot"/>
 <type name="Competitive"/>
   <buy name="Province"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Curse"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="1.0"/>
      </condition>
   </buy>
   <buy name="Ill_Gotten_Gains"/>
   <buy name="Duchy"/>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Duchy"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="5.0"/>
      </condition>
   </buy>
   <buy name="Silver"/>
</player>

Performance against WW bot:
  Win: 57.7% +/- 0.4%
  Loss: 38.7% +/- 0.4%
  Tie: 3.6% +/- 0.2%

Performance against BMU:
  Win: 95.3% +/- 0.2%
  Loss: 4.2% +/- 0.2%
  Tie: 0.5% +/- 0.1%

WW bot's performance against BMU, for comparison:
  Win: 95.1% +/- 0.2%
  Loss: 4.5% +/- 0.2%
  Tie: 0.4% +/- 0.1%
« Last Edit: February 16, 2012, 11:53:24 pm by blueblimp »
Logged

DG

  • Governor
  • *****
  • Offline Offline
  • Posts: 4074
  • Respect: +2624
    • View Profile
Re: Project: Optimizing Big Money X
« Reply #70 on: February 17, 2012, 09:31:55 am »
0

I wouldn't worry about optimizing igg against pure money as (1) it wins so strongly already and (2) pure money certainly isn't optimized for playing against curse givers. Buying estates and copper with bad hands should still be in the igg script somewhere but unfortunately the timing and benefit is largely masked by the variance. You can also gain 1% by not buying the final igg when you would immediately empty three piles and lose on points.
« Last Edit: February 17, 2012, 09:37:22 am by DG »
Logged

WanderingWinder

  • Adventurer
  • ******
  • Offline Offline
  • Posts: 5275
  • ...doesn't really matter to me
  • Respect: +4381
    • View Profile
    • WanderingWinder YouTube Page
Re: Project: Optimizing Big Money X
« Reply #71 on: February 17, 2012, 09:43:26 am »
0

...
Very very nice. I made a couple more slight improvements below. I'm pretty sure tweaking when the copper buys happen can help still, but... it's extremely extremely marginal.

Code: [Select]
<player name="IGG Rush"
 author="WanderingWinder"
 description="Get all the Ill-Gotten Gains and Duchies to empty 3 piles.">
 <type name="TwoPlayer"/>
 <type name="SingleCard"/>
 <type name="Bot"/>
 <type name="UserCreated"/>
 <type name="Province"/>
 <type name="Competitive"/>
 <type name="BigMoney"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Duchy"/>
         <operator type="equalTo" />
         <right type="constant" attribute="1.0"/>
      </condition>
      <condition>
         <left type="countCardsInSupply" attribute="Curse"/>
         <operator type="equalTo" />
         <right type="constant" attribute="0.0"/>
      </condition>
      <condition>
         <left type="countCardsInSupply" attribute="Ill_Gotten_Gains"/>
         <operator type="equalTo" />
         <right type="constant" attribute="0.0"/>
      </condition>
   </buy>
   <buy name="Ill_Gotten_Gains">
      <condition>
         <left type="countCardsInSupply" attribute="Duchy"/>
         <operator type="equalTo" />
         <right type="constant" attribute="0.0"/>
      </condition>
      <condition>
         <left type="countCardsInSupply" attribute="Curse"/>
         <operator type="equalTo" />
         <right type="constant" attribute="1.0"/>
      </condition>
      <condition>
         <left type="countCardsInSupply" attribute="Ill_Gotten_Gains"/>
         <operator type="equalTo" />
         <right type="constant" attribute="1.0"/>
      </condition>
      <condition>
         <left type="countVP"/>
         <operator type="greaterOrEqualThan" />
         <right type="countMAXOpponentVP"/>
      </condition>
   </buy>
   <buy name="Province"/>
   <buy name="Duchy">
      <condition>
         <left type="countCardsInSupply" attribute="Curse"/>
         <operator type="smallerThan" />
         <right type="constant" attribute="2.0"/>
      </condition>
   </buy>
   <buy name="Ill_Gotten_Gains"/>
   <buy name="Duchy"/>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Duchy"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="6.0"/>
      </condition>
   </buy>
   <buy name="Silver"/>
   <buy name="Estate">
      <condition>
         <left type="countCardsInSupply" attribute="Duchy"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="7.0"/>
      </condition>
   </buy>
   <buy name="Copper">
      <condition>
         <left type="gainsNeededToEndGame"/>
         <operator type="smallerOrEqualThan" />
         <right type="constant" attribute="7.0"/>
      </condition>
   </buy>
</player>
This gets a 49.107-47.112-3.781 over yours.
The main difference is that I buy estates even earlier.

I think the biggest gain left is from working in reshuffle-based stuff.

blueblimp

  • Margrave
  • *****
  • Offline Offline
  • Posts: 2849
  • Respect: +1559
    • View Profile
Re: Project: Optimizing Big Money X
« Reply #72 on: February 17, 2012, 02:41:24 pm »
0

I wouldn't worry about optimizing igg against pure money as (1) it wins so strongly already and (2) pure money certainly isn't optimized for playing against curse givers. Buying estates and copper with bad hands should still be in the igg script somewhere but unfortunately the timing and benefit is largely masked by the variance. You can also gain 1% by not buying the final igg when you would immediately empty three piles and lose on points.

I was meaning to use BMU as a stand-in for "whatever province strategy", although (as you point out) it does so badly that maybe it's a bad comparison. It might be better to compare against doublejack (using the bot included with the simulator), which is pretty good against IGG, but not overwhelmingly so.

WW's old IGG vs doublejack:
  Win: 40.1% +/- 0.4%
  Loss: 58.1% +/- 0.4%
  Tie: 1.8% +/- 0.1%

My IGG vs doublejack:
  Win: 41.4% +/- 0.4%
  Loss: 56.6% +/- 0.4%
  Tie: 2.0% +/- 0.1%

WW's new IGG vs doublejack:
  Win: 37.4% +/- 0.4%
  Loss: 60.9% +/- 0.4%
  Tie: 1.7% +/- 0.1%

WW's new IGG vs my IGG:
  Win: 49.0% +/- 0.4%
  Loss: 47.3% +/- 0.4%
  Tie: 3.7% +/- 0.2%


So we have a problem here where it's not clear what it means to be "optimized". WW's new bot is a bit better in the mirror than my bot, but a bit worse against doublejack.
Logged

DG

  • Governor
  • *****
  • Offline Offline
  • Posts: 4074
  • Respect: +2624
    • View Profile
Re: Project: Optimizing Big Money X
« Reply #73 on: February 17, 2012, 04:25:38 pm »
0

Quote
So we have a problem here where it's not clear what it means to be "optimized". WW's new bot is a bit better in the mirror than my bot, but a bit worse against doublejack.

There isn't a perfect definition so I wouldn't worry too much. A big money optimized to play against iggs would probably contest a duchy rush itself and would probably even buy iggs. There's very little reason not to.
Logged

Cheese

  • Swindler
  • ***
  • Offline Offline
  • Posts: 16
  • Respect: +23
    • View Profile
Re: Project: Optimizing Big Money X
« Reply #74 on: March 05, 2012, 08:04:31 pm »
0

Excellent project! The compiled XML is dated in September 2011, is there a newer state of things available somewhere?

Also, I checked about 10 sample games of the Ironworks bot and...it didn't buy a single Ironworks. Even fiddling with the buy rules a smidge, I couldn't get the bot to purchase an Ironworks. Simulator bug?
Logged
Pages: 1 2 [3] 4  All
 

Page created in 0.063 seconds with 21 queries.