Interface Curses et client en python pour vindinium (
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

4.5 KiB


Python/Curses user interface for the Vindinium A.I contest.

1 - Licence:

This software is published and copyrighted by Doug Le Tough
( and released under the W.T.F.P.L.

It was initially based upon the Vindium python starter available here :

A copy of the W.T.F.P.L is available in the LICENCE.txt file
that should accompany this source code.

For further information about the WTFPL please

2 - Content:

a -
    The random A.I. This is where to put your A.I code

b -
    The bot object source code. Collects data processed.

    The changelog, you may read it.

d -
    The client source code used to connect to game server

e - vindinium_curses_ui.png
    A screenshots of the running U.I

f - vindinium_curses_ui_menu.png
    Some screenshots of the setup menus

g -
    Source code used to process data sent by the server

    A copy of the W.T.F.P.L

i -
    This file

    The famous TODO list

k -
    The curses U.I. source code

3 - Goal:

The main goal of this project is to provide a solution to people
running their bots on a server and who'd like to view their
bots' activity in real-time without using the http connection
graciously provided by Vindinium.

This U.I to Vindinium is usable in a terminal and using an ssh
connection also permits reducing network latency.

It also provides a convenient way to save to and load configuration
and games from file allowing game later playback.

4 - Prerequities:

a - An Unix-like system (Linux/BSD/MacOSX/...)
    Due to some limitations of the underlying operating system,
    Windows is not not supported by this program.
    The work needed to make it work with Windows is not so
    hard but it is not a top priority for now.
    However, in a near future, this program should run over Windows.

b - A terminal or a terminal emulator such xterm able to display
    colors and supports least a 48 lines X 150 columns resolution.
    This software will work nicely with terminal multiplexers like
    screen or tmux

c - Python3 (was tested with 3.6)

d - The python-requests modules

e - The python-curses modules

5 - How to make it work:

The file contains the code of your bot.
With the file, it's merely the only file you'll need to play with.

Many comments are dissiminated within the source code.
They shall help you to understand how to plug your A.I to the U.I.

In order to make it work, you simply need to launch the client with
one of the following commands :

    a - python <key> <[training|arena]> <number-of-games-to-play> [server-url]

        In this case the starting setup menu will not be shown


        python mySecretKey arena 10
        python mySecretKey training 10 http://localhost:9000

    b - python

        In this case the setup menu will be displayed and will ask you
        some basic infos to get connected to the server.

You may post your question about this project to
or to the #vindinium IRC channel. The latter may be a
faster way to obtain answers but an email should always be privileged
as it guaranties an first-hand answer.

6 - Note :

The code provided here do NOT contains any AI or path-finding code
but only a random AI (hey, This YOUR job to put it up).

However it would run fine as is but would only win by mistake :)

Curses U.I running a game Main menu Game mode selection Number of games input (Arena mode) Server URL input Player key input Save config screen Play game screen Number of turns input (Training mode) Game map selection (Training mode) Game file path input Game file URL input