It seems to be caused by rounding the decoration values when rendering the scene, since the sample tool actually samples the on-screen buffer rather than the deco-colour of the particle, it inherits the issue from rendering. I don't see any point fixing this, since it's a performance optimisation causing the issue.
@Simon(View Post) Actually, it looks like the r, g, and b values just decrease by 1 every time no matter what, so it's not a rounding problem. If for example r is 1, or it's 255, when you sample it you'll get 0 and 254, so adding 1 to each will fix it.
The problem is the ">> 8", used instead of "/ 255" when blending colours in render_parts (and other places, but render_parts is the function causing this particular problem). ">> 8" is equivalent to dividing by 256.
The maximum alpha value (cola, deca, firea) is 255. 255 >> 8 = 255 / 256 which is less than 1, rounding error occurs, and the resulting RGB values are slightly too small.
Changing ">> 8" to "/ 255" does fix the issue, but I haven't tested what the impact on performance is.
Even, if there is rounding error, I found out that it's always the same, so you can just add 1 to each color value as long as its not 0, and that will mostly fix it except for when r, g, or b is 1. There's no need to change all those if this way is easier.