mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-08-03 23:36:59 -04:00
Fix particle systems not being rendered in their first frame
This commit is contained in:
parent
a45335ffc3
commit
c45013c983
@ -1038,10 +1038,12 @@ namespace NifOsg
|
|||||||
if (!(animflags & Nif::NiNode::ParticleFlag_AutoPlay))
|
if (!(animflags & Nif::NiNode::ParticleFlag_AutoPlay))
|
||||||
{
|
{
|
||||||
partsys->setFrozen(true);
|
partsys->setFrozen(true);
|
||||||
// HACK: particle system will not render in Frozen state if there was no update
|
|
||||||
osg::NodeVisitor nv;
|
|
||||||
partsys->update(0.0, nv);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Due to odd code in the ParticleSystemUpdater, particle systems will not be updated in the first frame
|
||||||
|
// So do that update manually
|
||||||
|
osg::NodeVisitor nv;
|
||||||
|
partsys->update(0.0, nv);
|
||||||
}
|
}
|
||||||
|
|
||||||
// affectors must be attached *after* the emitter in the scene graph for correct update order
|
// affectors must be attached *after* the emitter in the scene graph for correct update order
|
||||||
|
Loading…
x
Reference in New Issue
Block a user