Automated Client for generals.io
Python
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
base Add directed commands (for when there are multiple bots) Mar 29, 2018
tools
.gitignore Cache tile.neighbors Oct 14, 2017
Dockerfile Default to bot server May 2, 2017
License.txt Started Generals Bot Jan 6, 2017
README.md Add custom player commands Mar 2, 2018
__init__.py Added game viewer Jan 6, 2017
bot_blob.py Update author Mar 7, 2018
bot_control.py Update author Mar 7, 2018
bot_path_collect.py Update author Mar 7, 2018
bot_test.py Update author Mar 7, 2018
requirements.txt Add human controlled bot Nov 13, 2017
startup.py Update author Mar 7, 2018

README.md

Generals.io - Automated Client

Generals.IO Gameplay Image

Synopsis

Generals.io is a multiplayer web game where the goal is to protect your general and capture the enemy generals.

This is a collection of various automated clients (bots) for playing Generals.io. The project includes a toolkit for creating bots, as well as a UI viewer for watching live games.

Project available on GitHub.

Setup

Usage

  • Blob Bot: python3 bot_blob.py [-name] [-g gameType] [-r roomID]

  • Path Bot: python3 bot_path_collect.py [-name] [-g gameType] [-r roomID]

  • Run Forever: forever start -c python3 bot_blob.py -name BotName -g ffa

Features

Bots

  • bot_blob.py
    • move_toward: Run largest army to nearest priority target
    • move_outward: Move Border Armies Outward
  • bot_path_collect.py
    • Primary Path Routine: Run path from largest city to primary target
      • Continue running after reaching primary target
    • Collect Troops Routine (Run largest army toward nearest path tile)
    • Move Border Armies Outward
    • Proximity Targeting

Sample Code

  • samples/nearest.py: Run largest army to nearest priority target

Contributors

@harrischristiansen HarrisChristiansen.com (code@harrischristiansen.com)