It won't cause an OOS. Random numbers are all over the simulation and they do no harm in OOS'es. This due to the simple fact that it are all pseudo-random numbers. Basically, there is a set list of numbers, which is randomly created at the start of the match and agreed by all clients, used for all the random numbers generated in game.(The first call of a random function will give the first entry on the list and so on) So all clients will have the same random number at each instant a random number is asked for.
Also see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Math/random
You can check your commands.txt which has the random seed in the header. That is how replays keep in sync too.