/ Published in: ActionScript
Small function that returns a random rounded value between two given numbers.
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
public function getRandom(_min, _max):Number{ var tNumber:Number; tNumber = Math.round(Math.random()*(_max-_min))+_min; return tNumber; } // END getRandom()