Skip to content

Commit

Permalink
Refactoring: add unified debug mode. Closes lord-server#1561
Browse files Browse the repository at this point in the history
  • Loading branch information
alek13 committed Jul 19, 2024
1 parent e51bfe5 commit 26beb5f
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions mods/lord/Core/builtin/src/mod.lua
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,15 @@ minetest.get_mod_require = require_module.get_mod_require
function minetest.mod(mod_init_function)
local mod_name = minetest.get_current_modname()
local mod_path = minetest.get_modpath(mod_name)
local mod_debug = minetest.settings:get_bool(mod_name .. ".debug", debug_mode)

local old_require = require
require = minetest.get_mod_require(mod_name, mod_path)

mod_init_function({
name = mod_name,
path = mod_path,
debug = mod_debug,
require = require,
})

Expand Down

0 comments on commit 26beb5f

Please sign in to comment.