Merge Lodestone base #7

Merged
chmodsayshello merged 8 commits from Lodestone into Lodestone_tabspace_fix_2 2022-03-28 16:21:25 +02:00
1 changed files with 2 additions and 2 deletions
Showing only changes of commit d8986b4a4c - Show all commits

View File

@ -24,7 +24,7 @@ function mcl_compass.get_compass_image(pos, dir, x, y, z)
if dim == playerdim then --Check if player and compass target are in the same dimension, above check is just if the diemension is valid for the non lodestone compass
local spawn = {x=x,y=y,z=z}
local ssp = minetest.setting_get_pos("static_spawnpoint")
if ssp then
if ssp and x == 0 and y == 0 and z == 0 then
spawn = ssp
if type(spawn) ~= "table" or type(spawn.x) ~= "number" or type(spawn.y) ~= "number" or type(spawn.z) ~= "number" then
spawn = {x=0,y=0,z=0}
@ -45,7 +45,7 @@ function mcl_compass.get_compass_image(pos, dir, x, y, z)
if dim == playerdim then --already explained that very same if statement above
local spawn = {x=x,y=y,z=z}
local ssp = minetest.setting_get_pos("static_spawnpoint")
if ssp then
if ssp and x == 0 and y == 0 and z == 0 then
spawn = ssp
if type(spawn) ~= "table" or type(spawn.x) ~= "number" or type(spawn.y) ~= "number" or type(spawn.z) ~= "number" then
spawn = {x=0,y=0,z=0}