mirror of
https://git.minetest.land/MineClone2/MineClone2.git
synced 2024-11-05 07:13:51 +01:00
Fix player speed on soul sand, https://git.minetest.land/MineClone2/MineClone2/issues/1356
This commit is contained in:
parent
66a64439c6
commit
910c9083e5
@ -252,13 +252,7 @@ minetest.register_globalstep(function(dtime)
|
|||||||
playerphysics.add_physics_factor(player, "speed", "mcl_playerplus:surface", 0.4)
|
playerphysics.add_physics_factor(player, "speed", "mcl_playerplus:surface", 0.4)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
else
|
elseif get_item_group(node_feet, "liquid") ~= 0 and mcl_enchanting.get_enchantment(player:get_inventory():get_stack("armor", 5), "depth_strider") then
|
||||||
-- Reset speed decrease
|
|
||||||
playerphysics.remove_physics_factor(player, "speed", "mcl_playerplus:surface")
|
|
||||||
end
|
|
||||||
|
|
||||||
-- Swimming? Check if boots are enchanted with depth strider
|
|
||||||
if get_item_group(node_feet, "liquid") ~= 0 and mcl_enchanting.get_enchantment(player:get_inventory():get_stack("armor", 5), "depth_strider") then
|
|
||||||
local boots = player:get_inventory():get_stack("armor", 5)
|
local boots = player:get_inventory():get_stack("armor", 5)
|
||||||
local depth_strider = mcl_enchanting.get_enchantment(boots, "depth_strider")
|
local depth_strider = mcl_enchanting.get_enchantment(boots, "depth_strider")
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user