• Visit Rebornbuddy
  • Visit Panda Profiles
  • Visit LLamamMagic
  • API starting guide - Custom Deck

    Discussion in 'HearthBuddy Custom Decks' started by hankerspace, May 18, 2014.

    Thread Status:
    Not open for further replies.
    1. kispy

      kispy New Member

      Joined:
      May 10, 2014
      Messages:
      34
      Likes Received:
      0
      Trophy Points:
      0
      Oh.....How can our normal users improve the bot...The longer I use,the more problems I encounter..
      Now they are driving me crazy.
       
    2. hankerspace

      hankerspace DEVELOPER Buddy Core Dev

      Joined:
      Apr 4, 2014
      Messages:
      164
      Likes Received:
      3
      Trophy Points:
      0
    3. NiklasNikke

      NiklasNikke New Member

      Joined:
      Jul 15, 2010
      Messages:
      129
      Likes Received:
      1
      Trophy Points:
      0
      Instead of learning a programming language I'd recommend reporting all bugs you encounter. This would be the best way to help I think.
       
    4. HEADSTYLE

      HEADSTYLE New Member

      Joined:
      Jul 2, 2013
      Messages:
      399
      Likes Received:
      2
      Trophy Points:
      0
      Hello I have a question? Do I need the codes? Or the bot running without it?
       
    5. hankerspace

      hankerspace DEVELOPER Buddy Core Dev

      Joined:
      Apr 4, 2014
      Messages:
      164
      Likes Received:
      3
      Trophy Points:
      0
      There is a behavior included in Hearthbuddy, it works without any additions. Just start the bot and click on Play button.
       
    6. Diuuude

      Diuuude New Member

      Joined:
      Mar 28, 2014
      Messages:
      27
      Likes Received:
      0
      Trophy Points:
      0
      The bot will run without the need of anything. This API is only used by third party developpers who want to create specific behaviors for their custom decks.

      You can expect an average of 50% wins in ranked mode, playing a deck loaded with minions and just a few spells. If you prefer playing in practice mode, you can get 90% wins, or even more.
       
    7. Shadosky

      Shadosky New Member

      Joined:
      May 22, 2014
      Messages:
      22
      Likes Received:
      1
      Trophy Points:
      0
      Screenshot_Pre-Alpha.png

      The pre-Alpha version of my custom "Rush murloc deck" work pretty well in practice mode...

      Someone else have starting to dev something ?
       
    8. Diuuude

      Diuuude New Member

      Joined:
      Mar 28, 2014
      Messages:
      27
      Likes Received:
      0
      Trophy Points:
      0
      Working on a control paladin custom deck. Working pretty good but I can't get the best results untill I can choose what card I keep / discard at beginning. This is a very important part of almost any deck. Got 65,7% - 70,1% win rate in casual after 6h55 and 4h30 sessions.

      I first started with a control druid, but the double choice cards are really a pain to use :D that's why I switched to paladin.

      Btw I tried your custom deck, it's working pretty well too. Good job!
       
    9. Shadosky

      Shadosky New Member

      Joined:
      May 22, 2014
      Messages:
      22
      Likes Received:
      1
      Trophy Points:
      0
      Thank you :D

      Muligan will be added soon in the API ;)
       
    10. voidx

      voidx Member

      Joined:
      Aug 20, 2012
      Messages:
      175
      Likes Received:
      1
      Trophy Points:
      18
      What about API to get cards played by the opponent the last turn?
      false for localplayer gives minons only ?

      how exactly to get spell cards played by oponent last turn?
       
      Last edited: May 27, 2014
    11. b0rn

      b0rn Member

      Joined:
      Jun 26, 2012
      Messages:
      52
      Likes Received:
      1
      Trophy Points:
      8
      DEV will correct me if i'm wrong, but there's a function called

      Triton.Game.Mapping.HistoryInfoType.CARD_PLAYED
       
    12. hankerspace

      hankerspace DEVELOPER Buddy Core Dev

      Joined:
      Apr 4, 2014
      Messages:
      164
      Likes Received:
      3
      Trophy Points:
      0
      Currently you dont have any way to retrieve card history. It will be added in API upgrade.

      Actually, the getCard function returns cards CURRENTLY on the board or in hand. True or false is to determine is we should retrieve localplayer (our) cards our enemy cards. Take a look at the samples to get how it works.

      As i said, you cant. Anyway i think its cant be really helpfull. Even if you know a class has about 20 different card class, you are not sure what kind of cards enemy could have in his deck.
      The only utility to a such method could be for usual card. Such as flamestrike for a mage. However, how can be sure he has 2 flamestrike in his deck? And how to manage this information? Ok he drops one flamestrike, maybe he could use another one... I'll not drop any minions with health above 5?

      If you have an idea, lets talk about it, maybe it could give me some ideas.

      Ps: braum, this is the enum of Card history. It will be usefull to retrieve history cards but functions are not implemented, so you can't use it currently.
       
    13. Diuuude

      Diuuude New Member

      Joined:
      Mar 28, 2014
      Messages:
      27
      Likes Received:
      0
      Trophy Points:
      0
      I guess it's mostly for some cards like the mage's sheep, the hunter's UTH, the shamans's hex... Tbh, that's the only reason I can see. I mostly play Paladin and I usualy use buffs on cards early in the game to get rid of opponent's CC cards. Then I can play my big boys without any chance to get them sheeped of hexed the next turn. Could be very useful for control decks. A rush deck wouldn't care to get a murloc turned into a sheep.

      For me, the most important update would be to be able to choose our cards at the start of the game. Moe than this... humm, I don't see.
       
    14. voidx

      voidx Member

      Joined:
      Aug 20, 2012
      Messages:
      175
      Likes Received:
      1
      Trophy Points:
      18
      Currently on ranked most people play similar decks for a given class. Based on the cards played already, we can maintain a list and based on that decide what play we want to make.

      If enemy has played Divined Shield or given a minion divine shield, then Blood Knight in zoo deck takes priority.

      Enemy is playing a popular paladin deck that uses 1 big game hunter.
      I have 2 cards in my hand. Ironbark and Rag. If enemy has already played big game hunter then play rag first or else play ironbark first.

      If enemy druid has already played 2 swipes then you can trade in a fashion that leaves many minions at 1 health. Or else you will have to trade differently if he has not used 2 swipes.
      If mage has not played even 1 flamestrike then single high health minions take priority over many small creatures that give board contorl.

      If enemy hunter has already played 2 explosive traps. Then we would first play big minion and then small minion, because it could deal 4 damage on entering to small minion.
      if hunter has already wasted 2 hounds, we can spam the board.
       
    15. Shadosky

      Shadosky New Member

      Joined:
      May 22, 2014
      Messages:
      22
      Likes Received:
      1
      Trophy Points:
      0
      i don't think you really understand how difficult is your request...
       
    16. Candix

      Candix New Member

      Joined:
      May 29, 2014
      Messages:
      1
      Likes Received:
      0
      Trophy Points:
      0
      Hi,

      I'm trying to use your API to make a "generic architecture" for custom decks and I have a question: is it possible to get cards played by the ennemi ?
      We can determine which minion he played this turn with the current battlefield and the battlefield of previous turn, but I don't know how to "catch" his spells (like "equality", "divine spirit", "fireball", ...).

      The goal is to store played cards to determine if it's more or less safe to play a particular card.
       
    17. Meko

      Meko New Member

      Joined:
      May 21, 2014
      Messages:
      4
      Likes Received:
      0
      Trophy Points:
      0
      come on dude...like..for real... hankerspace answered this 4 posts above you, this thread has 4 pages, you could read them before asking something. It's actually faster than asking.

      "What about API to get cards played by the opponent the last turn?
      Currently you dont have any way to retrieve card history. It will be added in API upgrade."
       
    18. Rosarias

      Rosarias New Member

      Joined:
      Jun 28, 2014
      Messages:
      3
      Likes Received:
      0
      Trophy Points:
      0
      I am currently working on improving the API and will have a release soon for deckbuilding and AI improvements based on actual player information.

      Can someone please post the code for selecting the cards to Mulligan or reading and returning the card ID's for a function.

      Also if possible, returning the information on the cards generated from a card like tracking.

      Thanks

      EDIT: If there is a more advanced API listing for variables that would be good too. The changelog mentions alot of new instances but I fail to find them in any documentation.
       
      Last edited: Jun 28, 2014
    19. hankerspace

      hankerspace DEVELOPER Buddy Core Dev

      Joined:
      Apr 4, 2014
      Messages:
      164
      Likes Received:
      3
      Trophy Points:
      0
      Mulligan is currently managed by the default bot. API regarding mulligan's selection will come soon.

      I will add last functions changes in documentation soon.
       
    20. bow100

      bow100 New Member

      Joined:
      Aug 24, 2012
      Messages:
      77
      Likes Received:
      0
      Trophy Points:
      0
      Do you plan to add quest api?

      :rolleyes:
       
    Thread Status:
    Not open for further replies.

    Share This Page