Skip to content

matthewlai/hex0ad

Repository files navigation

hex0ad

Tile-based strategy game using 0ad assets.

This project is still in very early stages, and at the moment only a renderer and parsing code to load 0ad actors have been written.

A web version showcasing the current state of the project can be found at: https://matthewlai.ca/hex0ad.

A modern browser supporting WebGL 2 and WebAssembly is required (eg. modern Chrome, Firefox, Edge, or Safari).

BUILD

Requirements

Linux (Debian-based, including Raspberry Pi 4)

  • SDL2 SDL ttf, GLEW, CMake
    • sudo apt install libsdl2-dev libsdl2-ttf-dev libglew-dev libxml2-dev cmake
  • Flatbuffers
    • sudo apt install flatbuffers-compiler flatbuffers-compiler-dev libflatbuffers-dev
    • cp -r /usr/include/flatbuffers fb
  • FCollada for converting assets (https://github.com/matthewlai/fcollada)
    • git clone https://github.com/matthewlai/fcollada.git
    • cd fcollada
    • cmake . -DCMAKE_INSTALL_PREFIX=/usr
    • make MAKE="make -j6" && sudo make install

Windows

macOS

  • Install Homebrew (https://brew.sh/)
  • Install dependencies
    • brew install sdl2 sdl2_ttf flatbuffers libxml2 cmake pkg-config
  • Copy flatbuffers headers into the project
    • cp -r `pkg-config --cflags-only-I flatbuffers|cut -c 3-`/flatbuffers fb/
  • Set up libxml2 for pkg-config to find
    • brew info libxml2 to see instructions (set PKG_CONFIG_PATH in $HOME/.bash_profile or $HOME/.zshrc)
  • FCollada for converting assets (https://github.com/matthewlai/fcollada)
    • git clone https://github.com/matthewlai/fcollada.git
    • cd fcollada
    • cmake .
    • Build with make -j 6 && make install (or as appropriate for how many CPU cores you have)

Download and convert 0ad Assets (All Platforms)

  • See 0ad_assets/readme.txt for instructions to download 0ad assets (currently based on Alpha 26: Zhuangzi)
  • Convert assets to hex0ad format:
    • OPT=-O3 make
    • bin/make_assets

Build the game

  • OPT=-O3 make

Run the game

  • bin/hex0ad

Build with Emscripten (web)

About

Tile-based strategy game using 0ad assets

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published