Fix extra respawning particles

This commit is contained in:
vlj 2014-10-01 01:19:49 +02:00
parent 83053e0ee4
commit 2236e8dd1c

View File

@ -35,7 +35,7 @@ void main(void)
float updated_lifetime = lifetime + (float(dt)/lifetime_initial);
if (updated_lifetime > 1.)
{
if (gl_VertexID <= level)
if (gl_VertexID < level)
{
float dt_from_last_frame = fract(updated_lifetime) * lifetime_initial;
vec4 updated_initialposition = sourcematrix * vec4(particle_position_initial, 1.0);