Add source code and include lua_async as submodule

master
Elias Fleckenstein 2021-08-06 19:22:31 +02:00
parent d990959c4d
commit cbef4c8f8d
4 changed files with 20 additions and 0 deletions

3
.gitmodules vendored Normal file
View File

@ -0,0 +1,3 @@
[submodule "src"]
path = src
url = https://github.com/EliasFleckenstein03/lua_async

15
init.lua Normal file
View File

@ -0,0 +1,15 @@
local path = minetest.get_modpath(minetest.get_current_modname()) .. "/src/"
dofile(path .. "init.lua")(path)
minetest.register_globalstep(function(dtime)
lua_async.step(dtime)
end)
function lua_async.mt_validate_objs(...)
for _, ref in ipairs {...} do
if not ref:is_player() and not ref:get_luaentity() then
coroutine.yield(true)
end
end
end

1
mod.conf Normal file
View File

@ -0,0 +1 @@
name = lua_async

1
src Submodule

@ -0,0 +1 @@
Subproject commit a2770298f040307f8dd59c7a88d7e40d37faec14