ccrma / webchuck

ChucK on the Web
https://chuck.stanford.edu/webchuck
MIT License
42 stars 8 forks source link

Math.randomize() inconsistent behavior #40

Open tae1han opened 5 months ago

tae1han commented 5 months ago
Math.randomize();
Math.randomf() => float val;

<<<val>>>;

Using Math.randomize() does not seem to reset the random seed, and actually seems to explicitly seed the RNG. Above code gives the same value for Math.randomf() when run successively.

terryzfeng commented 4 months ago

Was able to reproduce this behavior in the IDE. A bit low priority but worth taking a look at the randomizer for web again @gewang.