4f5d2bbb29
Add conf.chai loading |
||
---|---|---|
docs | ||
examples | ||
jni | ||
src | ||
test | ||
vendor | ||
.editorconfig | ||
.gitignore | ||
.gitmodules | ||
.travis.yml | ||
appveyor.yml | ||
CHANGELOG.md | ||
configure | ||
COPYING | ||
link.T | ||
Makefile | ||
Makefile.common | ||
Makefile.libretro | ||
README.md |
ChaiLove ❤️
ChaiLove is an awesome framework you can use to make 2D games in ChaiScript. It's free, open-source, and works on Windows, Mac OS X, Linux, Android, and ARM through libretro/RetroArch.
Gallery
Installation
ChaiLove is a libretro core, which can be installed through RetroArch.
- Run RetroArch
- Online Updater → Core Updator → ChaiLove
Usage
Floppy Bird is a free game you can download and play...
- Run RetroArch
- Online Updater → Content Downloader → ChaiLove → FloppyBird.chailove
- Load Content → Downloads → FloppyBird.chailove
Alternatively, you can run the ChaiLove core through RetroArch via the command line:
curl -o FloppyBird.chailove https://github.com/RobLoach/ChaiLove-FloppyBird/releases/download/0.27.0/FloppyBird.chailove
retroarch -L chailove_libretro.so FloppyBird.chailove
API
The ChaiLove API is roughly inspired by the LÖVE API. The following main.chai
is a simple Hello World example:
global logo
global x = 10.0f
def load() {
logo = love.graphics.newImage("logo.png")
}
def draw() {
love.graphics.print("Hello World!", 400, 300)
love.graphics.draw(logo, x, 100)
}
def update(dt) {
x = x + 20.0f * dt
}
To run it, execute the following:
retroarch -L chailove_libretro.so main.chai
See the ChaiLove API for coverage of all the callbacks and methods in ChaiLove.
Development
The following are some notes about the development process behind ChaiLove.
Compiling
ChaiLove requires a C++14 compiler, and has been tested with g++>=5.2
. To compile it, run:
make
Testing
The automated tests can be run with:
make test
Run the testing suite through RetroArch with:
retroarch -L chailove_libretro.so test/main.chai
Documentation
See the ChaiLove API documentation. Build it through Doxygen by using:
make docs
Workflow
ChaiLove uses modified Gitflow and Semantic Versioning workflow...
- New features and fixes are added to the
dev
branch - When a release is put out, the
dev
branch is merged tomaster
, and a tag is made
Contributors
The following individuals contributed to ChaiLove in some way:
- @RobLoach
- @webgeek1234 for the Android support
- @r-type for his work on sdl-libretro
- @mudlord for his work on the libretro-common audio system
- @orbea
- @fetzerch
- @bparker06
- @twinaphex
- @ToKe79
- @baxysquare for the Logo