From 125df19477055a8e33b25aaafa05f5c59fd32626 Mon Sep 17 00:00:00 2001 From: Tiger Wang Date: Sun, 28 Mar 2021 14:41:34 +0100 Subject: Do not fake a tool when converting to pickups (#5170) * When the cause of destruction was world-induced (CanBeAt check failed) there is no tool. Pass the nullptr directly to ConvertToPickups and let it handle it. * Fixes #4795 - Remove unused a_Digger parameter to ConvertToPickups. --- src/Blocks/BlockPiston.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/Blocks/BlockPiston.cpp') diff --git a/src/Blocks/BlockPiston.cpp b/src/Blocks/BlockPiston.cpp index ee8620308..d9deedfc8 100644 --- a/src/Blocks/BlockPiston.cpp +++ b/src/Blocks/BlockPiston.cpp @@ -340,7 +340,7 @@ void cBlockPistonHeadHandler::OnBroken( -cItems cBlockPistonHeadHandler::ConvertToPickups(NIBBLETYPE a_BlockMeta, const cEntity * a_Digger, const cItem * a_Tool) const +cItems cBlockPistonHeadHandler::ConvertToPickups(const NIBBLETYPE a_BlockMeta, const cItem * const a_Tool) const { // Give a normal\sticky piston base, not piston extension // With 1.7, the item forms of these technical blocks have been removed, so giving someone this will crash their client... -- cgit v1.2.3