Add minetest.global_exists()
This commit is contained in:
parent
c2dcb45bf8
commit
6e61c7d92a
|
@ -4,6 +4,11 @@
|
|||
local WARN_INIT = false
|
||||
|
||||
|
||||
function core.global_exists(name)
|
||||
return rawget(_G, name) ~= nil
|
||||
end
|
||||
|
||||
|
||||
local function warn(message)
|
||||
print(os.date("%H:%M:%S: WARNING: ")..message)
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue