Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Stokes <kupomail@gmail.com>2014-04-15 23:44:49 +0400
committerDaniel Stokes <kupomail@gmail.com>2014-04-16 00:06:56 +0400
commit70f089b6f5b768b7ee0d6bc98d64a202e99fc22f (patch)
tree9f29cdf3c078431ab9a081a207734b5f11abd6b3
parent556590fa3a9757f5ee21d923ce38471c343495b7 (diff)
Fix T39509: Crash when assign an empty as a LoD
Missing check when looking for appropriate LoD
-rw-r--r--source/gameengine/Ketsji/KX_GameObject.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/gameengine/Ketsji/KX_GameObject.cpp b/source/gameengine/Ketsji/KX_GameObject.cpp
index f1f12caed19..ec64d09d147 100644
--- a/source/gameengine/Ketsji/KX_GameObject.cpp
+++ b/source/gameengine/Ketsji/KX_GameObject.cpp
@@ -759,7 +759,7 @@ void KX_GameObject::UpdateLod(MT_Vector3 &cam_pos)
Object *bob = this->GetBlenderObject();
LodLevel *lod = (LodLevel*) bob->lodlevels.first;
for (; lod; lod = lod->next, level++) {
- if (!lod->source) level--;
+ if (!lod->source || lod->source->type != OB_MESH) level--;
if (!lod->next || lod->next->distance * lod->next->distance > distance2) break;
}