From 5e81024f890fcbee0f0959655e9ad7806fd9f956 Mon Sep 17 00:00:00 2001 From: peterbell10 Date: Thu, 10 Aug 2017 18:11:27 +0100 Subject: cBeaconEntity fix no world crash --- src/BlockEntities/BeaconEntity.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/BlockEntities/BeaconEntity.cpp b/src/BlockEntities/BeaconEntity.cpp index 24de9e25c..a772290dd 100644 --- a/src/BlockEntities/BeaconEntity.cpp +++ b/src/BlockEntities/BeaconEntity.cpp @@ -19,7 +19,10 @@ cBeaconEntity::cBeaconEntity(BLOCKTYPE a_BlockType, NIBBLETYPE a_BlockMeta, int m_SecondaryEffect(cEntityEffect::effNoEffect) { ASSERT(a_BlockType == E_BLOCK_BEACON); - UpdateBeacon(); + if (m_World != nullptr) + { + UpdateBeacon(); + } } -- cgit v1.2.3