diff options
| author | Federico Angelilli <code@fedang.net> | 2025-04-12 17:40:28 +0200 |
|---|---|---|
| committer | Federico Angelilli <code@fedang.net> | 2025-04-12 17:40:28 +0200 |
| commit | 47dfeaa43f263896ad8ce13701f8a65c489f0bb9 (patch) | |
| tree | 600f00943bf2bde5f84e783bebf3fc12060c191f /src/lua/api.c | |
| parent | fd2ef765de733fbbbb15e28c91df255da36d5338 (diff) | |
Start working on Lua bindings
Diffstat (limited to 'src/lua/api.c')
| -rw-r--r-- | src/lua/api.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/lua/api.c b/src/lua/api.c new file mode 100644 index 0000000..5a29cca --- /dev/null +++ b/src/lua/api.c @@ -0,0 +1,14 @@ +#include "api.h" + + +bool lua_api_init(lua_api_t *api) +{ + api->state = luaL_newstate(); + luaL_openlibs(api->state); + return true; +} + +void lua_api_close(lua_api_t *api) +{ + lua_close(api->state); +} |
