瀏覽代碼

Adds a sanity check in the event we don't actually have any animation frames generated.

Areloch 9 年之前
父節點
當前提交
59637bb1c7
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      Engine/source/T3D/fx/particleEmitter.cpp

+ 1 - 1
Engine/source/T3D/fx/particleEmitter.cpp

@@ -1702,7 +1702,7 @@ void ParticleEmitter::setupBillboard( Particle *part,
       lVerts->color = partCol; } \
 
    // Here we deal with UVs for animated particle (billboard)
-   if (part->dataBlock->animateTexture)
+   if (part->dataBlock->animateTexture && !part->dataBlock->animTexFrames.empty())
    { 
      S32 fm = (S32)(part->currentAge*(1.0/1000.0)*part->dataBlock->framesPerSec);
      U8 fm_tile = part->dataBlock->animTexFrames[fm % part->dataBlock->numFrames];