Quote:
i tend to think that if you want no predictability (wrong in my example) and a perfectly equal distribution you'll need at least one if-branch.
or while loop but yeah, you're right. and i reckon an if-branch is friendlier than a while-loop, because theoretically the while loop could wait forever (at least in my case, though as mentioned earlier technically a computer would never allow that with its random lookup table).
ventilator's is accurate enough for anyone's purposes (if you're really fussy, add more powers of 5, if you know what i mean), but nVidia's rules may not have much leeway.
@anyone adding more suggestions: if you add any rand5()'s together without multiplying them to keep them out of each other's range, you will almost definitely suffer from dice-syndrome (i don't know if that's a real expression; probably not). keep an eye out for that. ventilator's mentioned at least a few times that this is a problem.
julz
Formerly known as JulzMighty. I made KarBOOM!
|