If you don't already know what this is, this is probably not for you!
Slate2D is my toy 2D engine. It is small, but not minimal. It has an API modelled after fantasy consoles, but without any designed restrictions in place. Slate2D is programmer-centric; you'll want to be familiar with C/C++, and have the ability to build and debug the engine yourself. Slate2D gives you the blank slate (get it??) to let you code.
Slate2D will feel somewhat familiar for anyone who has ever worked with engines like Source, Quake, or Doom. Convars, commands, and
binds are all present. Everything is provided through a library,
libslate2d. This keeps the game's entry point relatively simple.
A game loop with mouse, keyboard, and controller support including rebindable keys only requires a few functions.
Slate2D uses Premake5 to generate project files. The engine should generally run on Windows, Mac, Linux,
and WASM/Emscripten, but only Windows and Mac are often checked. Run a premake command such as
premake5 vs2019 to generate the project,
premake5 --help to see extra options specific to the project. An attempt has been made to make it build clean out of the box. This
has been confirmed to work on two different computers!
- Asset loader to let you work with asset handles instead of files
- PNG images: Including alpha channels
- Spritesheets: Minimize draw calls by drawing subimages
- Fonts: TTF and sprite-based, drawn out of an atlas
- Audio: OGG and tracker formats
- Tilemaps: Draw a grid of tiles based on an integer array
- Shaders: Customize drawing of shapes and sprites
- Canvas: Draw onto an off-screen texture
- Text to Speech: The most important
- Built in object inspector for scripting objects
- Watch for changed files, and run a command on modification
- Optional automatic sprite atlas packer
- No documentation
- Inconsistent usage of C and C++ patterns, and code style
- It mostly works!
- SDL - windowing, OpenGL context, input, DLL support
- QuickJS - embedded scripting language
- PhysicsFS - virtual filesystem, zip loading
- dear imgui - debugging tools
- SoLoud - audio engine
- GLEW - GL extension support
- rlgl - OpenGL wrapper
- crunch - sprite packing
Despite the self-deprecating feature list, Slate2D has successfully been used in two game jam games!
Hot Air - a Balloon Fight style game.
Clive Sturridge's Battlement Defence - a mix of tower defense and Rampart.