forked from VoxeLibre/VoxeLibre
make player not walk while using elytra
This commit is contained in:
parent
b4374fe961
commit
d466693f27
|
@ -91,7 +91,7 @@ local function update_player_textures(player)
|
||||||
end
|
end
|
||||||
|
|
||||||
player:set_properties({ textures = textures })
|
player:set_properties({ textures = textures })
|
||||||
|
|
||||||
-- Delay calling the callbacks because mods (including mcl_player)
|
-- Delay calling the callbacks because mods (including mcl_player)
|
||||||
-- need to fully initialize player data from minetest.register_on_joinplayer
|
-- need to fully initialize player data from minetest.register_on_joinplayer
|
||||||
-- before callbacks run
|
-- before callbacks run
|
||||||
|
@ -234,6 +234,8 @@ minetest.register_globalstep(function(dtime)
|
||||||
-- Apply animations based on what the player is doing
|
-- Apply animations based on what the player is doing
|
||||||
if player:get_hp() == 0 then
|
if player:get_hp() == 0 then
|
||||||
player_set_animation(player, "die")
|
player_set_animation(player, "die")
|
||||||
|
elseif mcl_playerplus.elytra[player] and mcl_playerplus.elytra[player].active then
|
||||||
|
player_set_animation(player, "stand")
|
||||||
elseif walking and velocity.x > 0.35
|
elseif walking and velocity.x > 0.35
|
||||||
or walking and velocity.x < -0.35
|
or walking and velocity.x < -0.35
|
||||||
or walking and velocity.z > 0.35
|
or walking and velocity.z > 0.35
|
||||||
|
|
Loading…
Reference in New Issue