From 8656e149c8820272a882406912790f0075ed5f28 Mon Sep 17 00:00:00 2001 From: Tiger Wang Date: Tue, 30 Jun 2015 15:50:15 +0100 Subject: Improved maps --- src/Entities/Player.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/Entities') diff --git a/src/Entities/Player.cpp b/src/Entities/Player.cpp index 97e2eca3a..adbaf1104 100644 --- a/src/Entities/Player.cpp +++ b/src/Entities/Player.cpp @@ -205,6 +205,7 @@ void cPlayer::Tick(std::chrono::milliseconds a_Dt, cChunk & a_Chunk) if (m_ClientHandle->IsDestroyed()) { // This should not happen, because destroying a client will remove it from the world, but just in case + ASSERT(!"Player ticked whilst in the process of destruction!"); m_ClientHandle = nullptr; return; } @@ -215,6 +216,10 @@ void cPlayer::Tick(std::chrono::milliseconds a_Dt, cChunk & a_Chunk) return; } } + else + { + ASSERT(!"Player ticked whilst in the process of destruction!"); + } m_Stats.AddValue(statMinutesPlayed, 1); -- cgit v1.2.3