Only load the default ranks.lua file if the world directory does not already contain one. it makes no sense to load 2 ranks.lua files.
This commit is contained in:
parent
5dd9b20b52
commit
98311a2ed3
4
init.lua
4
init.lua
@ -419,10 +419,10 @@ end
|
||||
---
|
||||
|
||||
-- Load default ranks
|
||||
dofile(minetest.get_modpath("ranks").."/ranks.lua")
|
||||
|
||||
local path = minetest.get_worldpath().."/ranks.lua"
|
||||
-- Attempt to load per-world ranks
|
||||
if io.open(path) then
|
||||
dofile(path)
|
||||
else
|
||||
dofile(minetest.get_modpath("ranks").."/ranks.lua")
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user