Stop player from dropping when they teleport through portals

This commit is contained in:
oilboi 2020-04-24 09:54:00 -04:00
parent 0601e4069e
commit 01510fb7d5
2 changed files with 4 additions and 4 deletions

View File

@ -274,7 +274,7 @@ local function teleport_to_overworld(blockpos, action, calls_remaining, param)
if portal_exists then
--print(teleporting_player)
if teleporting_player then
teleporting_player:set_pos(portal_exists)
teleporting_player:set_pos(vector.new(portal_exists.x,portal_exists.y-0.5,portal_exists.z))
end
end
teleporting_player = nil
@ -286,7 +286,7 @@ local function teleport_to_aether(blockpos, action, calls_remaining, param)
if portal_exists then
--print(teleporting_player)
if teleporting_player then
teleporting_player:set_pos(portal_exists)
teleporting_player:set_pos(vector.new(portal_exists.x,portal_exists.y-0.5,portal_exists.z))
end
end
teleporting_player = nil

View File

@ -277,7 +277,7 @@ local function teleport_to_overworld(blockpos, action, calls_remaining, param)
if portal_exists then
--print(teleporting_player)
if teleporting_player then
teleporting_player:set_pos(portal_exists)
teleporting_player:set_pos(vector.new(portal_exists.x,portal_exists.y-0.5,portal_exists.z))
end
end
teleporting_player = nil
@ -289,7 +289,7 @@ local function teleport_to_nether(blockpos, action, calls_remaining, param)
if portal_exists then
--print(teleporting_player)
if teleporting_player then
teleporting_player:set_pos(portal_exists)
teleporting_player:set_pos(vector.new(portal_exists.x,portal_exists.y-0.5,portal_exists.z))
end
end
teleporting_player = nil