Skip to content

ninovanhooff/wheelsprung

Repository files navigation

Wheelsprung (Playdate)

Screenshot

A physics-based motocross-platformer for the Playdate console. Made with the Nim programming language and the Chipmunk2D physics library for playdate. It relies on 2 libraries for that:

Playdate-Nim

Chipmunk2D for Playdate

Level Editor

A public level editor is available. See the guide on the Wiki for installation and usage instructions.

Installation

NOTE: Although this repository is publicly available, the level files are not. You may be able to compile the project, but will have to provide your own level files to run the game.

This project should work on MacOS and Windows. See Playdate-Nim for installation instructions.

Troubleshooting

As noted above, the level files are not included. This may be a cause for crashes.

Make sure you can run the playdate-nim sample project

See Playdate-Nim for installation instructions.

Linux support

All the necessities to run on Linux should be in place, but the Linux build target is not maintained and last checked a long time ago.

Development

As noted above, the level files are not included. This may be a cause for crashes.

Level hash updater

./scripts/run_level_updater.sh

Tiled extension

To build the Tiled extension every time you save changes to the typescript files:

cd editor/extensions
npm run watch

...or select the Node.js > Run Script: watch from the Run and Debug dropdown

Chipmunk

The Chipmunk physics library comes bundled as a pre-compiled static library. For future reference; this is how I was able to compile it for Mac and Linux. For Windows, I used tdm-gcc.

mkdir build
cd build
cmake --fresh -G "MinGW Makefiles" -D BUILD_STATIC=ON -D BUILD_SHARED=OFF -D BUILD_DEMOS=OFF -D INSTALL_STATIC=OFF -D CMAKE_BUILD_TYPE=Debug -D PLAYDATE=ON ../
cmake --build .

The resulting lib is placed in the lib folder.