Chris Adams wrote:
OK I've done some debugging for the particle error.
The text below is my output from when I fire the pistol - the Assert() that
it mentions is the line *after* the DevMsg line, so you can see that most of
the particles don't cause errors when being sorted, just a few. Looking at
the ones that have the problem, the min and max Z values are the same?
Please let me know what you think:
Divide by zero in particlemgr.cpp line 728:
float flPercent = (zCoords[iCurParticle] - minZ) / (maxZ - minZ);
...this probably should be...
float flPercent = 0.0f;
if (abs(maxZ - minZ) > 0.00001) // avoid nasty divide by zero problem
flPercent = (zCoords[iCurParticle] - minZ) / (maxZ - minZ);
--
Jeffrey "botman" Broome
_______________________________________________
To unsubscribe, edit your list preferences, or view the list archives, please
visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders