Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using Sabberstone for an UI project/bachelor's work... #12

Closed
AzGhort opened this issue Apr 6, 2017 · 2 comments
Closed

Using Sabberstone for an UI project/bachelor's work... #12

AzGhort opened this issue Apr 6, 2017 · 2 comments

Comments

@AzGhort
Copy link

AzGhort commented Apr 6, 2017

[I know that message like that probably doesn't belong here, but I wrote you an email, and I am not sure whether it arrived...]

Hi,
I am a student of Software engineering at Charles University in Prague and I am working on a software project themed on AI for Hearthstone. My goal is to develop some AIs, let them play against each other, and then evaluate which one are the "best". There has been a similar work at my school that used Fireplace (https://is.cuni.cz/webapps/zzp/detail/177312/23634918/?lang=en - it's written in Slovakian though :)), but since Fireplace seems really outdated now, I decided to try your simulator.

Is there any module in Sabberstone (or, are you planning to write one), where you can evaluate whole number of games with given decks (and strategies, maybe)? I know that there is a turn-based GUI, but I will probably need something for simulating of a big number of games automatically.
I can even implement something like that based on your project myself, but I haven't got inside Sabberstone that much yet... I would look on wiki, but there is not much info yet :)

Could you also please tell me more about API of SabberstoneCore, if needed?

Anyway, thanks for your reply and keep up the good work!

@citiral
Copy link
Contributor

citiral commented Apr 6, 2017

Hey! I'm not the developer of Sabberstone (That's @darkfriend77), so I dont know much about the inner workings, but i've been working with @darkfriend77 to connect SabberStone with Stove, so I think I can answer most of your questions about how to interface with it.

If you hit me up on Discord in HearthSim we can talk. I'm online most of the time (and from Belgium so same time zone).

But in short, if you take a look at Program.RandomGames() in SabberStoneCoreAI, that tells most of the story of how to interface with the simulator. The core game loop exists out of the simulator giving a list of all possible options the current player can do, using game.CurrentPlayer.Options().
These options are all specialisations of PlayerTask, and most are fairly explanatory. You have a ChooseTask for mulligan and discover, an EndTurnTask, A HeroAttackTask,..

It's also worth of note that each task in that list represents a single action, and not a group of actions. By this I mean that if you have a minion that has 4 possible targets to attack, there will be 4 seperate MinionAttackTasks in that list. Same goes for the mulligan, there isn't 1 ChooseTask, but there is one for each possible combinations of cards to mulligan.

@AzGhort
Copy link
Author

AzGhort commented Apr 6, 2017

Hi, thanks for your super-fast reply... The Program.RandomGames() in SabberStoneCoreAI is exactly what I needed for the beginning, thanks :)
I am on Discord as well, so thanks again, I will definitely contact you or darkfriend77 for some support when needed!

@AzGhort AzGhort closed this as completed Apr 10, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants