Skip to content

aren227/prime-composition

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

62 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

prime-composition

thumbnail

A 2D game project built on raylib. C++17 / CMake / macOS, Windows, Web (Emscripten).

Play in browser: https://aren227.itch.io/prime-composition

Prerequisites

Common

  • CMake 3.24+
  • Ninja
  • LLVM clang/clang++ (Apple Clang is fine on macOS)
  • Emsdk (for web build)

macOS

brew install cmake ninja llvm

Windows

Web (Emscripten)

git clone https://github.com/emscripten-core/emsdk.git
cd emsdk && ./emsdk install latest && ./emsdk activate latest
source ./emsdk_env.sh       # Windows: emsdk_env.bat

The $EMSDK environment variable must be set (via emsdk_env) before configuring the web preset.

Build

Standalone (macOS, Windows)

cmake --preset standalone-debug
cmake --build --preset standalone-debug
./build/standalone-debug/prime-composition

Web

source /path/to/emsdk/emsdk_env.sh
cmake --preset web-debug
cmake --build --preset web-debug
python3 -m http.server 8000 --directory build/web-debug
# Open http://localhost:8000/index.html

Swap *-debug for *-release for release builds.

Packaging

./tools/build_web.sh [debug|release]          # mac
./tools/build_standalone.sh [debug|release]
.\tools\build_web.ps1 -BuildType release      # windows
.\tools\build_standalone.ps1 -BuildType release

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors