update to newer 0.4.16 functions
This commit is contained in:
@@ -2,16 +2,17 @@
|
||||
local S = protector.intllib
|
||||
|
||||
-- get static spawn position
|
||||
local statspawn = minetest.setting_get_pos("static_spawnpoint") or {x = 0, y = 2, z = 0}
|
||||
local statspawn = minetest.string_to_pos(minetest.settings:get("static_spawnpoint"))
|
||||
or {x = 0, y = 2, z = 0}
|
||||
|
||||
-- is pvp protection enabled
|
||||
protector.pvp = minetest.setting_getbool("protector_pvp")
|
||||
protector.pvp = minetest.settings:get_bool("protector_pvp")
|
||||
|
||||
-- is night-only pvp enabled
|
||||
protector.night_pvp = minetest.setting_getbool("protector_night_pvp")
|
||||
protector.night_pvp = minetest.settings:get_bool("protector_night_pvp")
|
||||
|
||||
-- disables PVP in your own protected areas
|
||||
if minetest.setting_getbool("enable_pvp") and protector.pvp then
|
||||
if minetest.settings:get_bool("enable_pvp") and protector.pvp then
|
||||
|
||||
if minetest.register_on_punchplayer then
|
||||
|
||||
|
||||
Reference in New Issue
Block a user