16
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-07-21 17:09:19 +02:00

lua changes, smooth train brake

This commit is contained in:
milek7
2017-12-29 16:12:08 +01:00
parent 1d028e2539
commit 19d4c51915
5 changed files with 145 additions and 110 deletions

View File

@@ -36,6 +36,9 @@ const char lua_ffi[] = "local ffi = require(\"ffi\")\n"
"local module = {}\n"
"\n"
"module.event_create = ns.scriptapi_event_create\n"
"function module.event_preparefunc(f)\n"
" return ffi.cast(\"void (*handler)(TEvent*, TDynamicObject*)\", f)\n"
"end\n"
"module.event_find = ns.scriptapi_event_find\n"
"function module.event_getname(a)\n"
" return ffi.string(ns.scriptapi_event_getname(a))\n"