aboutsummaryrefslogtreecommitdiff
path: root/builtin
diff options
context:
space:
mode:
Diffstat (limited to 'builtin')
-rw-r--r--builtin/game/register.lua10
1 files changed, 9 insertions, 1 deletions
diff --git a/builtin/game/register.lua b/builtin/game/register.lua
index 398daf057..f330491a2 100644
--- a/builtin/game/register.lua
+++ b/builtin/game/register.lua
@@ -11,10 +11,11 @@ local register_alias_raw = core.register_alias_raw
core.register_alias_raw = nil
--
--- Item / entity / ABM registration functions
+-- Item / entity / ABM / LBM registration functions
--
core.registered_abms = {}
+core.registered_lbms = {}
core.registered_entities = {}
core.registered_items = {}
core.registered_nodes = {}
@@ -79,6 +80,13 @@ function core.register_abm(spec)
spec.mod_origin = core.get_current_modname() or "??"
end
+function core.register_lbm(spec)
+ -- Add to core.registered_lbms
+ check_modname_prefix(spec.name)
+ core.registered_lbms[#core.registered_lbms + 1] = spec
+ spec.mod_origin = core.get_current_modname() or "??"
+end
+
function core.register_entity(name, prototype)
-- Check name
if name == nil then