From be17d1a46788bebab895723b1040864e0797444b Mon Sep 17 00:00:00 2001 From: David Markowitz Date: Fri, 16 Jun 2023 02:02:33 -0700 Subject: [PATCH] Update DestroyableComponent.cpp --- dGame/dComponents/DestroyableComponent.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dGame/dComponents/DestroyableComponent.cpp b/dGame/dComponents/DestroyableComponent.cpp index 8c932fd1..59926b01 100644 --- a/dGame/dComponents/DestroyableComponent.cpp +++ b/dGame/dComponents/DestroyableComponent.cpp @@ -52,7 +52,7 @@ DestroyableComponent::DestroyableComponent(Entity* parent, int32_t componentId) m_IsGMImmune = false; m_IsShielded = false; m_DamageToAbsorb = 0; - m_IsModuleAssembly = m_Parent->HasComponent(eReplicaComponentType::MODULE_ASSEMBLY); + m_IsModuleAssembly = m_ParentEntity->HasComponent(eReplicaComponentType::MODULE_ASSEMBLY); m_DirtyThreatList = false; m_HasThreats = false; m_ExplodeFactor = 1.0f; @@ -79,7 +79,7 @@ void DestroyableComponent::Startup() { } void DestroyableComponent::LoadConfigData() { - SetIsSmashable(m_ParentEntity->GetVarAs(u"is_smashable") != 0); + SetIsSmashable(GetIsSmashable() | (m_ParentEntity->GetVarAs(u"is_smashable") != 0)); } void DestroyableComponent::LoadTemplateData() { if (m_ParentEntity->IsPlayer()) return;