Profile Treeform's Blog

Playtest Nov 8 - Saving, Loading, and Testing AIs

Nov 8, 2015

Play tests happen every Sunday at 23:00 UTC at http://www.istrolid.com I have added some commands to help save and load AIs (clears your AI rules and build bar):

ais.load(“Cython”)

You can load your own AI as well as build-in AIs. You can also save your own an AI, but not the build-in AIs.

ais.save(“Your-Name”)

This outputs an AI definition that you can give to me in a gist so that I can include them in the game, and it also saves it to your local storage.

Your-Name =
   "name":
       "Your-Name"
   "rules":
       [
           [...]
           [...]
           []
           []
           []
           []
           []
           []
           [...]
       ]
   "ships":
       [
           "FxAcERAcFBM...LEhY2FhY2"
           "FxcLERc...IdFRIdFBY2"
           ""
           ""
           ""
           ""
           ""
           ""
           ""
           "ERAdFxAdFBYTFBIPERQWFxQWERcsFxcs"
       ]

You can load your AI at any time:

ais.load(“Your-Name”)

I think that's pretty cool.

Testing

You can also test AIs at higher speeds by using special URL params:

http://www.istrolid.com/game.html?ai=TorpMan&speed=fast

ai is the AI name you want to fight against

speed tells it to go faster so that you can see the out come easier. When you are fighting it fast it's sometimes easier to use the P key to pause the game to inspect that the AI is thinking.

New Phase Bomb Graphics and Sound