selene
This example running in the browser is just a proof of concept, I'll keep updating it as soon as I develop new features.
What is selene?
Selene is a Lua game framework written in C, it has some builtin modules to help with game development (or any type of app, graphical or not). It's similtar to LÖVE, but the idea is to expose the functions of libraries like OpenGL and SDL2 to give more options to build a framework from scratch by the Lua side. Modules include font, audio and image loaders, mini wrapper for SDL2 (it can be extended in the future), OpenGL, JSON encode and decode. These are available as global modules, but selene has internal modules that implements renderer, audio system, and other low level stuff in the future.
The idea is to extend it with plugins as well, the modules are embedded in the engine and are developed only in C, but plugins can be developed in both C or Lua langs. With plugins I plan to develop high level stuff like resource managers, UI, editor, runner.
For examples of how to setup the main.lua file, start looking at the examples/
folder in https://github.com/canoi12/selene.
An example of main.lua
file:
selene("MyGame", "1.0.0", "org.selene.MyGame")
local render = selene.renderer.RenderBatch2D(selene.get_renderer())
selene.set_event(function(name, ...)
if name == 'quit' or name == 'window closed' then selene.set_running(false) end
end)
selene.set_step(function()
render:begin()
render:enable_3d()
render:clear(0.2, 0.3, 0.3)
render:draw_cube({ 32, 64, -32 }, { math.rad(15), math.rad(60), 0 }, { 32, 32, 32 })
render:disable_3d()
render:finish()
render:present()
end)
Updated | 10 days ago |
Status | In development |
Category | Tool |
Platforms | HTML5, Windows, Linux, Android |
Author | Canoi Gomes |
Made with | SDL |
Tags | framework, Game engine, lua |
Average session | Days or more |
Download
Click download now to get access to the following files:
Development log
- selene v0.4.110 days ago
- selene v0.4.019 days ago
- selene v0.3.025 days ago
- selene v0.2.167 days ago
- selene v0.2.0Dec 30, 2024