Hexxagon with Hexxagon AI

So I finally finished my Hexxagon AI project and now I have a new Hexxagon version and the first version of the Hexxagon AI!

The AI has 5 difficult levels that vary from pretty stupid to pretty good. Here is how to use it:

  • After being loaded to a Blink, the AI will display a spinning animation of a single face with the color of the user it will control when connected to the game.
  • Single-click will move to the next player (RED, BLUE, GREEN MAGENTA).
  • Double-click will switch to difficult selection. This will revert back to searching for a game after 2 seconds.
  • When in this mode, single-click will increase the difficulty level. When it reaches 5 it will go back to 1. Every click resets the 2 second timer mentioned above.

That is it, just connect this Blink to an Hexxagon game cluster and it will control the Player with the same color.

Here is what the animations mean:

  • Single spinning face: Searching for game.
  • Double spinning faces: Connected to another blink (any Blink) and waiting for the game map.
  • Triple slow-spinning faces: Map loaded, waiting for player turn.
  • Triple fast-spinning faces: Playing.

The AI can be connected/disconnected at any point.

Here are the binaries using the Blinks Installer:

https://www.bug-br.org.br/hexxagon-installer-linux-amd64.zip
https://www.bug-br.org.br/hexxagon-installer-darwin-amd64.zip
https://www.bug-br.org.br/hexxagon-installer-windows-amd64.zip

The installer includes both Hexxagon and the Hexxagon AI.

Here is the repository for the AI:

If you try it, let me know what you think!

4 Likes

Stickers!

1 Like

Also, I forgot to mention some changes to Hexxagon that went in on this release.

  • Against all odds, games can now be played with up to 128 Blinks (technically I could do maybe 10 more or so, but 128 is a nice power of 2 so I will leave it at that).
  • There has been tweaks to animations.
  • Move confirmation step removed. Now you click once to select the origin and another time to select the target AND confirm the move at the same time.
1 Like

Ok, I’m trying it out!

I’ve had some problems. I have the latest build of Hexxagon on 40 Blinks, and Hexxagon-AI on two.

If I connect the Hexxagon-AI Blinks to the board during setup (after clicking once in the startup mode) they switch to the two-sided spinning. If I then double-click, they keep two-sided spinning, and the adjacent Blinks seem to lock up. Long-press reset doesn’t seem to work, a sustained long press goes to the sleep mode.

I think I might need some more specific instructions as to when the AI Blinks need to connect.

In theory they can be connected at any point. But why were you trying to double click them after connecting? Level selection is done before connecting (when they are alone).

I’m double-clicking other Blinks on the board to start the game. So the sequence goes:

  1. Power up -> pulsing

  2. Click once to enter setup -> dim, no pulsing

  3. Connect AI Blinks (already set to blue and red)

  4. Double-click a yellow blink -> starts flickering game map learning

  5. Blinks adjacent to the AI Blinks are dim, rest are unresponsive.

Perhaps I should try one AI blink at a time?

Well, this is the first release, so there might be bugs. :slight_smile: But yes, try connecting them after the game starts and see if it works.

2 Likes

Nice sticker! If you want me to do the sticker with the same style font just tell me!

1 Like

Yeah, I just did a hack to have something. :slight_smile: If you are up to the task, I was thinking about something different but that still reminds of Hexxagon. Using the same fonts and maybe a different background (although I am not sure what exactly, but something that would associated with AIs would be cool).

1 Like

Sure! Actually I can see some options, something “Tron” style. Let me think on that, give me a couple of days :stuck_out_tongue_closed_eyes:

3 Likes

So I loaded up Hexxagon and the AI and was beaten 6 times in a row by the AI… Excited to play more and will happily share feedback on UX and of course any bugs spotted along the way.

Note: my setup was 18 Blinks (3 x 6 grid)

1 Like

Was it a typo or do you mean you pitched the AI against the AI? In any case, I actually have fun doing exactly that (60 Blinks in a game with 4 AIs against myself). I guess I am getting the hang of it as I manage to beat the AIs at least once. :slight_smile:

Please do. Note I am aware of at least one bug that results in the entire game stalling (and a re-seed is needed), but I think I know what the issue is and will fix it. I am also trying to get just a bit more space in Hexxagon itself to add back a full reset mode on it so even if this particular lockup happens, one can simply reset the game (needing to reseed is obviously not ideal).

2 Likes