From 0d0d019bbe6d7d6ce80056a6f249e69d5bb865bd Mon Sep 17 00:00:00 2001 From: Mat Date: Mon, 23 Mar 2020 22:07:08 +0200 Subject: Fix certain item drops (#4536) * Fix certain item drops * Revert unwanted changes * Revert unwanted changes * Revert change * Style fixes --- src/Blocks/BlockRedstoneRepeater.h | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'src/Blocks/BlockRedstoneRepeater.h') diff --git a/src/Blocks/BlockRedstoneRepeater.h b/src/Blocks/BlockRedstoneRepeater.h index 6e749bd57..de55debf1 100644 --- a/src/Blocks/BlockRedstoneRepeater.h +++ b/src/Blocks/BlockRedstoneRepeater.h @@ -12,9 +12,9 @@ class cBlockRedstoneRepeaterHandler: - public cClearMetaOnDrop> + public cMetaRotator { - using super = cClearMetaOnDrop>; + using super = cMetaRotator; public: @@ -32,6 +32,7 @@ public: { a_BlockType = m_BlockType; a_BlockMeta = RepeaterRotationToMetaData(a_Player.GetYaw()); + return true; } @@ -78,6 +79,11 @@ public: return false; } + virtual cItems ConvertToPickups(NIBBLETYPE a_BlockMeta, cBlockEntity * a_BlockEntity, const cEntity * a_Digger, const cItem * a_Tool) override + { + return cItem(E_ITEM_REDSTONE_REPEATER, 1, 0); + } + inline static NIBBLETYPE RepeaterRotationToMetaData(double a_Rotation) { a_Rotation += 90 + 45; // So its not aligned with axis -- cgit v1.2.3