ProtoBot
Loading...
Searching...
No Matches
Getting Started

Installation

ProtoBot is completely open source and you can download ProtoBot's files here:
https://github.com/Unclouded-JokR/StarCraftAI/

While the documentation for our project is lackluster at best, ProtoBot does provide a good idea on how you need to structure an agent to play StarCraft. Look at the DDS for a more detailed view of how ProtoBot works or inspect the visual studio project with the docmentation to help explain alittle of the purpose of each class/struct.

To start using ProtoBot, the game folder for StarCraft: Brood War is needed. This folder was not included in the GitHub repository to avoid taking up too much space.
Dr. Dave Churchill, a pioneer of the StarCraft Brood War AI competitive scene, provided a starting folder for executing StarCraft: Brood War AI bots that also includes the game itself.
If you installed the source code through the senior design blog post, everything BWAPI and StarCraft Related will be installed already. Note: StarCraft: Brood War has been approved for research and projects like this one with full permission from Blizzard Entertainment, the creator of StarCraft.

Please watch the following video on how learn to use BWAPI and change the config file, STARTCraft was the repository we used as a base for ProtoBot and provides alot of key knowledge of StarCraft Programming.

STARTCraft Tutoiral Video:
https://www.youtube.com/watch?v=FEEkO6__GKw

Get the files here:
https://davechurchill.ca/starcraft/files/startcraft/scbw_bwapi440.zip

If you downloaded the files from the GitHub repository, once installation is done, you can replace the contents of StarCraftAI/starcraft with all the files from the zip folder.

Running Final Executable Version of ProtoBot

Windows

To run ProtoBot on Windows, do the following:

Navigate to /StarCraftAI/bin and execute RunProtoBotAndStarcraft.bat.
This will launch up ProtoBot and StarCraft: Brood War.
ProtoBot will automatically connect to the game lobby and begin playing!

Linux

To run ProtoBot on Linux, run the following commands:

  
    sudo apt update
    sudo apt install build-essential mingw-w64 make
   

This will install make, linux g++ and a Windows cross-compiler i686-w64-mingw32-g++

Once installed, navigate to the makefile in the base StarCraftAI folder.
Edit the flag BIN_DIR to point to the path ./bin_linux.

Once all packages are installed and the BIN_DIR flag has been changed, go to the directory where the makefile is located (should be /StarCraftAI) and run the commands:

  
    make clean
    make
   

Running ProtoBot Through Visual Studio

To inspect and run the source code of ProtoBot through Visual Studio, all you will need to do is make sure you have Visual Studio 22 already installed and to open a solution.
To find the solution for ProtoBot look in the ./StarCraftAI/visualstudio/ directory and select the ProtoBot.sln file. This will automatically set up everything related to the project for you.
To compile and run the bot, click the Local Windows Debugger button at the top of the window on any of the following modes:

  • Debug 32
  • Debug 64
  • Release 32

For some reason Release 64 does not compile and I could not figure out why. It is most likely due to a project configuration setting specifically for that mode.

Note
Make sure to also set the ProtoBot project as the start up project. In the Solution Explorer Window (View -> Solution Explorer Window or (Ctrl + Alt + L)) right click the ProtoBot project (not the 'solution' ProtoBot) and set it as the start up project.

When you run, a terminal window will pop up saying "Game table mapping not found", naviagte to the ./StarCraftAI/starcraft directory and dobule click the RunStarcraftWithBWAPI.bat batch file. This will automatically start up the game if you downloaded the source code from the senior design blog post otherwise you will need to change the bwapi.ini configuration file in the ./StarCraftAI/starcraft/bwapi-data using a text editor of your choice.
I highly recommend watching the STARTCraft video at the top of this webpage as a tutorial to BWAPI.

Additional Documentation

Explanation of functions, classes, and namespaces such as BWAPI::Broodwar->draw...(), BWAPI::Position, BWAPI::Broodwar, etc. are documented in the BWAPI documentation.

BWAPI documentation:
https://bwapi.github.io/

For a list of usefull links and things our team learned during the course of the project, look in the senior design blog post for the "Document of All Things StarCraft: Brood War Programming".