int random_int ( int number1, [ int number2, [ bool exclusive ] ] )
This script returns a random integer between number1 and number2. It doesn't matter whether they are negative numbers or not or whether first is bigger than the second. The random number is always between the two given numbers. By default, the random number is inclusive (the limits are included), however if exclusive is specified as true, the border numbers are not included within the random numbers. Note that you don't necessarily need to define the second number, as then a number between the given number and 0 is returned (inclusive).
NOTE: If you specify exclusive random number and the limits are either the same number, or next to eachother, 0 is always returned (because the limits are invalid).
NOTE: Despite al the weirdness in GM's random function, this function will make sure that no odd values are returned. In case the function attemps to return an invalid value, a new random number is generated instead.