mirror of
https://git.minetest.land/VoxeLibre/VoxeLibre.git
synced 2024-11-26 20:41:11 +01:00
Fix crash when eating
This commit is contained in:
parent
b8a2149995
commit
dd05828281
1 changed files with 2 additions and 1 deletions
|
@ -79,7 +79,8 @@ function mcl_hunger.item_eat(hunger_change, replace_with_item, poisen, heal, sou
|
||||||
local hp = user:get_hp()
|
local hp = user:get_hp()
|
||||||
|
|
||||||
local pos = user:getpos()
|
local pos = user:getpos()
|
||||||
pos.y = pos.y + item_drop_settings.player_collect_height
|
-- player height
|
||||||
|
pos.y = pos.y + 1.5
|
||||||
local foodtype = minetest.get_item_group(itemname, "food")
|
local foodtype = minetest.get_item_group(itemname, "food")
|
||||||
if foodtype == 3 then
|
if foodtype == 3 then
|
||||||
-- Item is a drink, only play drinking sound (no particle)
|
-- Item is a drink, only play drinking sound (no particle)
|
||||||
|
|
Loading…
Reference in a new issue