Skip to content

cpp-gamedev/pkmn

Repository files navigation

PKMN

For Users: Playing the Game

Go to Releases and download the latest version of pkmn-x64-linux-windows-v1.0.0-*.zip. Unzip this directory, then

  • run easy_install.sh (Linux)
  • run EasyInstall.ps1 (Windows)

to configure the game. This process may take a minute or two depending on your internet connection. After that, run the pkmn binary (pkmn.exe on Windows) to start the game. The game takes up quite a bit of vertical space, so you may want to adjust the size of your terminal.

For Developers: Build & Debug the Game

Initialize and update all submodules after you have cloned this repository:

git submodule update --init --recursive

For python specifically, you may need to install python3-venv to create virtual environments on Linux.

Generating new Pokemon

If this is your first time using a python script, use

python -m venv venv/
source venv/bin/activate
python -m pip install --upgrade pip
pip install -r requirements.txt --only-binary all

to install the dependencies in a virtual environment. On Windows, you need to use .\venv\Scripts\Activate.ps1 to activate a virtual environment. Note that this script assumes that it is being run from the project's root directory. You need to create at least two new pkmn file sets before you can start playing this game:

# creates two new pkmns (bulbasaur and charmander)
python gen_data.py --verbose make --id 1 4
# creates a manifest.json
python gen_data.py manifest

In case of doubt, use

python gen_data.py --help

to get more help.

On Visual Studio (Windows)

Navigate to Project and select Generate Cache for pkmn. Set Current Document (main.cpp) to start debugging this project (F5).

On Visual Studio Code (Linux)

Useful links for first timers: