Hi!
I would like to recreate the clouds as displayed here: http://www.miniclip.com/sudoku/sudoku.htm. If someone could tell me how I can make the clouds apear random (height, speed, and maybe also transparency, shape)
Printable View
Hi!
I would like to recreate the clouds as displayed here: http://www.miniclip.com/sudoku/sudoku.htm. If someone could tell me how I can make the clouds apear random (height, speed, and maybe also transparency, shape)
use random(range) function
random(10)
every time u execute this function is gives a number between 1 & 10
so like that u can set different height,speed & transperancy..ect
Noor
Actually you get a number between 0-9.And since I rarely want a number between 0 and anything what I do is use this function to get a random number that is in the range I want.Quote:
Originally Posted by nooor83
function randomRange(Min,Max){
return random(Max-Min+1)+Min;
}
then when I need a random number say between 30 and 100
mynumber=root.randomRange(30,100)
NOTE IN THE PREVIEW THE NUMBERS WILL NOT BE RANDOM.
ohh..ya u r rigth..bw 0 & 10..
thanx anyway for the new function randomrange..
Noor