diff --git a/mods/creative/init.lua b/mods/creative/init.lua index cd9e2b4..7471e60 100644 --- a/mods/creative/init.lua +++ b/mods/creative/init.lua @@ -1,7 +1,9 @@ creative = {} +local creative_mode_cache = minetest.setting_getbool("creative_mode") + function creative.is_enabled_for(name) - return minetest.setting_getbool("creative_mode") + return creative_mode_cache end dofile(minetest.get_modpath("creative") .. "/inventory.lua")