From d9d1e5c08cc29ab21a73a4c540ffc79b8d1fa3f5 Mon Sep 17 00:00:00 2001 From: Wuzzy Date: Fri, 27 Sep 2019 12:09:03 +0200 Subject: [PATCH] Fix crash in mcl_fishing --- mods/ITEMS/mcl_fishing/init.lua | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/mods/ITEMS/mcl_fishing/init.lua b/mods/ITEMS/mcl_fishing/init.lua index be7bdbda18..ebef9ca92c 100644 --- a/mods/ITEMS/mcl_fishing/init.lua +++ b/mods/ITEMS/mcl_fishing/init.lua @@ -41,6 +41,7 @@ local fish = function(itemstack, player) noent = false if ent._dive == true then local itemname + local items local itemcount = 1 local itemwear = 0 -- FIXME: Maybe use a better seeding @@ -103,7 +104,7 @@ local fish = function(itemstack, player) local idef = itemstack:get_definition() itemstack:add_wear(65535/65) -- 65 uses if itemstack:get_count() == 0 and idef.sound and idef.sound.breaks then - minetest.sound_play(idef.sound.breaks, {pos=player.get_pos(), gain=0.5}) + minetest.sound_play(idef.sound.breaks, {pos=player:get_pos(), gain=0.5}) end end end @@ -117,7 +118,7 @@ local fish = function(itemstack, player) local idef = itemstack:get_definition() itemstack:add_wear((65535/65)*2) -- if so and not creative then wear double like in MC. if itemstack:get_count() == 0 and idef.sound and idef.sound.breaks then - minetest.sound_play(idef.sound.breaks, {pos=player.get_pos(), gain=0.5}) + minetest.sound_play(idef.sound.breaks, {pos=player:get_pos(), gain=0.5}) end end end