An open API service indexing awesome lists of open source software.

https://github.com/benzap/kampf

Flexible game engine written in C++, Scripting in Lua
https://github.com/benzap/kampf

c-plus-plus game-engine lua-bindings lua-scripting

Last synced: 2 months ago
JSON representation

Flexible game engine written in C++, Scripting in Lua

Awesome Lists containing this project

README

        

* What is Kampf
A game engine developed for 2d Games employing the entity component
game design pattern. Game scripting is done through the lua
programming language.

Currently, the kampf engine is in alpha and has been *discontinued*

You can see an example of a game written in Kampf [[https://github.com/benzap/Kampf-pong/blob/master/src/pong.lua][here]]

* Compatible Operating Systems
- Windows (mingw gcc 4.7+)
- Linux (gcc 4.7+)

* Compiling

** Prerequisites
Make sure to include all of the dependencies provided by each
prerequisite

All prerequisites must be on your environment path / Library path
in order to compile correctly

For Windows, Mingw should be on your path as well, along with with
Msys. ex. /C:\MinGW\bin;C:\MinGW\msys\1.0\bin/ within *PATH*

The easiest way to include the prerequisites, is to copy the
resulting ./include, ./lib, and ./bin folders over C:/MinGW for
the Windows binary folders for each. (Lua being an exception)

For Windows, the prerequisites must be i686-w64 versions
*** Lua
NOTE: you can also use LuaJit

- Website :: [[http://www.lua.org/download.html][here]]
*** SDL2 (Version 2+)
- Website :: [[http://www.libsdl.org/download-2.0.php][here]]
*** SDL_Image (Version 2+)
- Website :: [[https://www.libsdl.org/projects/SDL_image/][here]]
*** SDL_TTF (Version 2+)
- Website :: [[https://www.libsdl.org/projects/SDL_ttf/][here]]
** Win32
#+BEGIN_SRC
cd src
make
#+END_SRC

- Make sure that SDL2.0 and Lua5.1 are on your path. The makefile
might need to be edited to accomodate luajit instead of just
plain lua. Typically I place all of my libs and includes within
the mingw include/ and lib/ directory. In the future i'll
probably be providing snapshots of the latest compiled libraries
and includes.
- cd to src/
- make
- that's it!

If you want to look at the current test cases, run 'make tests'
and then run 'make runtests' to start running tests

NOTE: the kampf_interpreter runs at one point, which requires
you to type 'quit()' or 'exit()' in order to continue running
the other tests

** Linux
- Install the dependencies, you know what to do

* Dependencies
- Msys
- SDL2.0
- SDL_Image (2.0+)
- SDL_ttf (2.0+)
- Lua5.1 or Luajit2.0