From 07619d932d703611c2e3e1296871bee5e27876b7 Mon Sep 17 00:00:00 2001 From: Alexander Harkness Date: Tue, 16 Jan 2018 19:13:17 +0000 Subject: Exp Orbs and Pickups are destroyed instantly by cacti. (#4136) * Cactus detection code follows pattern set in #3996 * Pickups are now destroyed on cactus contact * Add cactus detection and destruction to Exp Orbs Remove checks for IsExpOrb() in cEntity::Tick() Exp Orbs do not call super::Tick() and so this condition was pointless. --- src/Entities/Pickup.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/Entities/Pickup.h') diff --git a/src/Entities/Pickup.h b/src/Entities/Pickup.h index 61e433e07..6b3d9f9f2 100644 --- a/src/Entities/Pickup.h +++ b/src/Entities/Pickup.h @@ -36,6 +36,8 @@ public: virtual void Tick(std::chrono::milliseconds a_Dt, cChunk & a_Chunk) override; + virtual bool DoTakeDamage(TakeDamageInfo & a_TDI) override; + virtual bool DoesPreventBlockPlacement(void) const override { return false; } /** Returns whether this pickup is allowed to combine with other similar pickups */ -- cgit v1.2.3