Skip to content

Instantly share code, notes, and snippets.

#include <cstdio>
#include <random>
#include "openbw/bwgame.h"
#include "openbw/actions.h"
int main() {
std::mt19937 rng(std::random_device{}());
#!/bin/sh
#
# This script plays a 1v1 with the bots and settings specified below.
# It spawns two instances of BWAPILauncher and communicates using pipes.
# No bwapi.ini is necessary; all settings are set using environment variables.
#
bot1="${bot1:-$1}"
race1="${race1:-$2}"
name1="${name1:-$(basename $bot1 .so)}"
git clone --recursive -b openbw https://github.com/tscmoo/TorchCraft.git
cd TorchCraft/BWEnv
mkdir build
cd build
cmake .. -DOPENBW_ENABLE_UI=ON
make