Dominion Strategy Forum

Please login or register.

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

Author Topic: Simulator Challenge(Dominate): Beat everything but SillyAI  (Read 13795 times)

0 Members and 1 Guest are viewing this topic.

ephesos

  • Explorer
  • *****
  • Offline Offline
  • Posts: 347
  • Shuffle iT Username: Ephesos
  • Respect: +291
    • View Profile
Re: Simulator Challenge(Dominate): Beat everything but SillyAI
« Reply #25 on: May 16, 2014, 04:26:38 am »
0

Lol, alright, you can't use any moves that wouldn't work in a real game of Dominion(no giving yourself all the VP chips, no deleting your opponent from existence, etc.) Also, no conditions on the name of the other AI; you can't just make a good AI and turn it into a self curser when it hears it's facing SillyAI.

Are you allowed to use other means to deduce that it's playing SillyAI? E.g. I could require Scout on board as the only $4, and turn the bot into a self-curser as soon as it detects his opponent buying a Scout.

Also, what happens if my strategy requires 10 specific kingdom cards and it's matched up against a strategy requiring 2 cards not included in the original 10? (I could test this but I'm lazy lol)

And... should it also work on Andrew's implementation of Dominiate? It includes more cards and some better strategies.
I'm not quite sure what to exclude here, since saying exactly what's needed could give it away. For now, I'll say that your AI can't use any way to tell what cards your opponent has bought, and is not allowed to buy Curses. Additionally, you can't use the name of the strategy in any way(if I rename SillyAI to ChapelWitch, you should still lose to it)
It currently doesn't work on Andrew's version: there are some strategies that are about 1% better than it, as far as I can tell; BigMoneyBaker is actually a lot better, but that's cause the AI doesn't quite know when to hold on to Coin tokens. Also, it required a few edits to even run(I had to add in a wantsToRebuild and a wantsToJM function, otherwise it would crash)
Also, for anyone thinking about maybe doing some probability hacks(e.g. it self curses 1 out of 100 games, and I just get really unlucky 10 times vs SillyAI), I ran it for 20000+ games in a row(overnight) to determine that it really won 51% vs one strategy(it does)
Wow, buying Chapel at 4 really helps the strategy. It no longer has ties anywhere close to 50%. But, just to prove I actually went through this process, I took a screenshot of it facing DoubleGhostShip for 25000+ games. It's in the attachment.
Logged

luser

  • Tactician
  • *****
  • Offline Offline
  • Posts: 447
  • Respect: +353
    • View Profile
Re: Simulator Challenge(Dominate): Beat everything but SillyAI
« Reply #26 on: May 16, 2014, 08:27:09 am »
0

I tried to implement pin, a bot now could get components easily. A first problem is that with kc-masq hand bot refuses kc a masquerade. How could I tell him what to pass and what to trash?

A starting bot is here:
Code: [Select]
{
  name: 'sillyfriend'
  requires: ['Militia', 'Masquerade', "Quarry", "King's Court"]
  gainPriority: (state, my) -> [
    "King's Court" if my.countInDeck("King's Court") < 2
    'Militia' if (my.countInDeck("King's Court") >= 2) && (my.countInDeck("Militia") < 1)
    "Masquerade" if my.countInDeck("Masquerade") < 2
    "Quarry" if my.countInDeck("Quarry") < 3
  ]
}
Wow, this was actually really close... Kudos! All I did past this, I guess, is I figured out how to tell him what to pass and trash(They're both actually the same priority in the code). And, I bought Chapel. That really helps, especially against things like DoubleMountebank

With quarry chapel will slow you down. With double masq opening and few quarries you quickly hit 7. That is problematic to add to bot (along with things like not trashing copper when you have 7 and so)

With added quarry and skipped chapel unless mountebank, following bot beats ghost ship 70% of times.


#Ruthlessly executes unsuspecting bots with the KC/Goons/Masquerade pin
{
  name: 'QuarryPin'
  requires: ["Chapel", "King's Court", "Masquerade", "Goons", "Quarry"]
  gainPriority: (state, my) -> [
    "King's Court" if my.countInDeck("King's Court") < 2
    "Goons" if my.countInDeck("Goons") == 0
   
   
    # If this bot somehow gets rid of its chapel later in the game,
    # it won't try to acquire another one.
    # "Chapel" if my.coins <= 4 and my.countInDeck("Chapel") == 0 and my.turnsTaken <= 2
    # Would be three, if it wasn't for that nasty Baker 4/4 split
    "Masquerade" if my.countInDeck("Masquerade") == 0
    "Quarry" if my.countInDeck("King's Court") < 2 && my.countInDeck("Quarry") < 4
   
    "Gold" if my.turnsTaken >= 50 #MAKE IT STOP
    "Duchy" if my.turnsTaken >= 70
    "Estate" if my.turnsTaken >= 90
    "Chapel" if my.countInDeck("Curse") > 0 and my.countInDeck("Chapel") < 2 #just to counter that nasty DoubleMountebank. Guess you sometimes do have to buy a second Chapel
  ]

  trashPriority: (state, my) -> [
    "Curse"
    "Estate"
    "Copper"
    "Silver" if my.countInDeck("King's Court") == 2 and my.countInDeck('Goons') == 1
    "Chapel"
    #kill anything once the pin starts
    "Gold" if my.countInDeck("King's Court") == 2 and my.countInDeck('Goons') == 1
    "Province" if my.countInDeck("King's Court") ==2 and my.countInDeck('Goons') == 1
    "Duchy" if my.countInDeck("King's Court") == 2 and my.countInDeck('Goons') == 1
    "King's Court" if my.countInDeck("King's Court") > 2 and my.countInDeck('Goons') == 1
    "Goons" if my.countInDeck("King's Court") == 2 and my.countInDeck('Goons') > 1
    "Masquerade" if my.countInDeck("King's Court") == 2 and my.countInDeck('Goons') == 1 and my.countInDeck('Chapel') == 0
    #anything else just trash
    "Witch"
    "Platinum"
    "Colony"
    "Wharf"
    "Monument"
    "Library"
    "Bank"
    "Envoy"
    "Smithy"
    "Mountebank"
    "Young Witch"
    "Ambassador"
    "Ghost Ship"
    "Jack of All Trades"
    "Militia"
    "Moneylender"
    "Adventurer"
    "Bazaar"
    "Bridge"
    "Chancellor"
    "Coppersmith"
    "Courtyard"
    "Hunting Party"
    "Nobles"
    "Remake"
    "Royal Seal"
    "Scheme"
    "Tournament"
    "Baron"
    #added these for Andrew's version
    "Advisor"
    "Beggar"
    "Gardens"
    "Journeyman"
    "Baker"
    "Vineyard"
    "University"
    "Scrying Pool"
    "Alchemist"
    "Potion"
    "Rats"
    "Masterpiece"
    "Feodum"
    "Duke"
    "Rebuild"
    "Horse Traders"
    "Rogue"
    "Plaza"
    "Quarry"
    #huh, new strategies, guess it has been a while
    "Oasis"
    "Watchtower"
    "Develop"
    "Festival"
    "Talisman"
  ]
 
  wantsToRebuild: (state, my) ->
    return 0
 
  wantsToJM: (state, my) ->
    false
 
  multipliedPriority: (state, card, my) -> [
    "King's Court"
    "Goons"
    "Masquerade"
    "Chapel"
  ]
}   
Logged
Pages: 1 [2]  All
 

Page created in 0.044 seconds with 20 queries.