removed race condition in updateValues::updateParticles