From 4036978718241b62cb532f13a9c987d5e467bac2 Mon Sep 17 00:00:00 2001 From: scrawl Date: Tue, 12 May 2015 16:50:31 +0200 Subject: [PATCH] Empty model exception fix --- apps/openmw/mwclass/light.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/openmw/mwclass/light.cpp b/apps/openmw/mwclass/light.cpp index 4d0c0cba9..1e882b568 100644 --- a/apps/openmw/mwclass/light.cpp +++ b/apps/openmw/mwclass/light.cpp @@ -48,7 +48,7 @@ namespace MWClass assert (ref->mBase != NULL); // TODO: add option somewhere to enable collision for placeable objects - if ((ref->mBase->mData.mFlags & ESM::Light::Carry) == 0) + if (!model.empty() && (ref->mBase->mData.mFlags & ESM::Light::Carry) == 0) physics.addObject(ptr, model); if (!ref->mBase->mSound.empty() && !(ref->mBase->mData.mFlags & ESM::Light::OffDefault))