From c968f1f7da722eddb291c8ef474f1e0394621911 Mon Sep 17 00:00:00 2001 From: Mat Date: Sun, 22 Mar 2020 17:33:36 +0200 Subject: TNT position fixes (#4519) * TNT position fixes * Don't add offset to explosion spawn coords * Don't make other entities push TNT * Correct initial TNT speed * Fix typo * Improvements * Revert unwanted change * Style fixes * Update format --- src/Entities/Entity.cpp | 2 +- src/Entities/TNTEntity.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'src/Entities') diff --git a/src/Entities/Entity.cpp b/src/Entities/Entity.cpp index 99f8b56b8..90683271a 100644 --- a/src/Entities/Entity.cpp +++ b/src/Entities/Entity.cpp @@ -972,7 +972,7 @@ void cEntity::HandlePhysics(std::chrono::milliseconds a_Dt, cChunk & a_Chunk) } } } - else + else if (!(IsMinecart() || IsTNT())) { // Push out entity. BLOCKTYPE GotBlock; diff --git a/src/Entities/TNTEntity.cpp b/src/Entities/TNTEntity.cpp index a86aa40e3..6ee56b92a 100644 --- a/src/Entities/TNTEntity.cpp +++ b/src/Entities/TNTEntity.cpp @@ -36,7 +36,7 @@ void cTNTEntity::Explode(void) m_FuseTicks = 0; Destroy(); FLOGD("BOOM at {0}", GetPosition()); - m_World->DoExplosionAt(4.0, GetPosX() + 0.49, GetPosY() + 0.49, GetPosZ() + 0.49, true, esPrimedTNT, this); + m_World->DoExplosionAt(4.0, GetPosX(), GetPosY(), GetPosZ(), true, esPrimedTNT, this); } -- cgit v1.2.3