decrease damage animspeed
parent
c3425a69b1
commit
3557f02b8f
|
@ -148,7 +148,7 @@ minetest.register_on_punchplayer(function(player, hitter, time_from_last_punch,
|
||||||
end
|
end
|
||||||
player:add_velocity({x=d.x*4,y=yy,z=d.z*4})
|
player:add_velocity({x=d.x*4,y=yy,z=d.z*4})
|
||||||
end
|
end
|
||||||
|
|
||||||
if hitter:is_player() then
|
if hitter:is_player() then
|
||||||
local wielditem = hitter:get_wielded_item()
|
local wielditem = hitter:get_wielded_item()
|
||||||
if wielditem then
|
if wielditem then
|
||||||
|
|
|
@ -232,9 +232,6 @@ minetest.register_globalstep(function(dtime)
|
||||||
local velocity = player:get_velocity() or player:get_player_velocity()
|
local velocity = player:get_velocity() or player:get_player_velocity()
|
||||||
|
|
||||||
local mod_speed = 5
|
local mod_speed = 5
|
||||||
if player:get_meta():get("punched") and tonumber(player:get_meta():get("punched")) > 0 then
|
|
||||||
mod_speed = 10
|
|
||||||
end
|
|
||||||
-- 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")
|
||||||
|
|
Loading…
Reference in New Issue