mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-02-21 09:09:41 +00:00
Fix the particle quota
This commit is contained in:
parent
41ce5464c9
commit
f764f243d2
2 changed files with 4 additions and 2 deletions
|
@ -165,6 +165,8 @@ public:
|
||||||
class NiAutoNormalParticlesData : public ShapeData
|
class NiAutoNormalParticlesData : public ShapeData
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
int numParticles;
|
||||||
|
|
||||||
float particleSize;
|
float particleSize;
|
||||||
|
|
||||||
int activeCount;
|
int activeCount;
|
||||||
|
@ -176,7 +178,7 @@ public:
|
||||||
ShapeData::read(nif);
|
ShapeData::read(nif);
|
||||||
|
|
||||||
// Should always match the number of vertices
|
// Should always match the number of vertices
|
||||||
nif->getUShort();
|
numParticles = nif->getUShort();
|
||||||
|
|
||||||
particleSize = nif->getFloat();
|
particleSize = nif->getFloat();
|
||||||
activeCount = nif->getUShort();
|
activeCount = nif->getUShort();
|
||||||
|
|
|
@ -1274,7 +1274,7 @@ class NIFMeshLoader : Ogre::ManualResourceLoader
|
||||||
|
|
||||||
partsys->setDefaultDimensions(particledata->particleSize, particledata->particleSize);
|
partsys->setDefaultDimensions(particledata->particleSize, particledata->particleSize);
|
||||||
partsys->setCullIndividually(false);
|
partsys->setCullIndividually(false);
|
||||||
partsys->setParticleQuota(particledata->activeCount);
|
partsys->setParticleQuota(particledata->numParticles);
|
||||||
|
|
||||||
Nif::ControllerPtr ctrl = partnode->controller;
|
Nif::ControllerPtr ctrl = partnode->controller;
|
||||||
while(!ctrl.empty())
|
while(!ctrl.empty())
|
||||||
|
|
Loading…
Reference in a new issue