Replace deprecated functions with newer ones (#131)

These commits makes more compatibility with MT/MTG 5.0.0+ versions.
However, these commits breaks compatibility with the 0.4-series.
This commit is contained in:
Panquesito7
2019-06-16 03:26:40 -05:00
committed by SmallJoker
parent a70ffb1509
commit 4403b696be
5 changed files with 16 additions and 9 deletions

View File

@ -174,7 +174,7 @@ minetest.register_on_player_receive_fields(function(player, formname, fields)
if fields["set_waypoint"..i] then
hit = true
local pos = player:getpos()
local pos = player:get_pos()
pos.x = math.floor(pos.x)
pos.y = math.floor(pos.y)
pos.z = math.floor(pos.z)