summaryrefslogtreecommitdiffstats
path: root/src/Blocks/ClearMetaOnDrop.h
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/Blocks/ClearMetaOnDrop.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/Blocks/ClearMetaOnDrop.h b/src/Blocks/ClearMetaOnDrop.h
new file mode 100644
index 000000000..21b987f2c
--- /dev/null
+++ b/src/Blocks/ClearMetaOnDrop.h
@@ -0,0 +1,18 @@
+
+#pragma once
+
+template<class Base>
+class cClearMetaOnDrop : public Base
+{
+public:
+
+ cClearMetaOnDrop(BLOCKTYPE a_BlockType) :
+ Base(a_BlockType)
+ {}
+
+ virtual ~cClearMetaOnDrop() {}
+ virtual void ConvertToPickups(cItems & a_Pickups, NIBBLETYPE a_BlockMeta) override
+ {
+ a_Pickups.push_back(cItem(this->m_BlockType, 1, 0));
+ }
+};