Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 16 additions & 7 deletions Core/GameEngine/Source/GameClient/System/ParticleSys.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1427,13 +1427,22 @@ void ParticleSystem::rotateLocalTransformZ( Real z )
// ------------------------------------------------------------------------------------------------
/** Attach this particle system to a Drawable */
// ------------------------------------------------------------------------------------------------
void ParticleSystem::attachToDrawable( const Drawable *draw )
{
if (draw)
m_attachedToDrawableID = draw->getID();
else
m_attachedToDrawableID = INVALID_DRAWABLE_ID;
}
void ParticleSystem::attachToDrawable( const Drawable *draw )
{
if (draw)
{
m_attachedToDrawableID = draw->getID();

#if defined(GENERALS_ONLINE_HIGH_FPS_RENDER)
// Info: One-frame attached systems can otherwise lose their only burst when the drawable is created and destroyed
// between legacy particle updates at 60Hz.
if (m_systemLifetimeLeft == 1 && m_delayLeft == 0 && getParticleCount() == 0)
update(0);
#endif
}
else
m_attachedToDrawableID = INVALID_DRAWABLE_ID;
}

// ------------------------------------------------------------------------------------------------
/** Attach this particle system to a Drawable */
Expand Down
Loading