barsuift.simLife
Class Randomizer
java.lang.Object
barsuift.simLife.Randomizer
public final class Randomizer
- extends java.lang.Object
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
random1
public static double random1()
- Returns:
- between -0.1 and 0.1
random2
public static double random2()
- Returns:
- between -0.5 and 0.5
random3
public static double random3()
- Returns:
- between -1 and 1
random4
public static double random4()
- Returns:
- between 0 and 0.1
randomBetween
public static int randomBetween(int min,
int max)
- Returns:
- random int between min and max
- Throws:
java.lang.IllegalArgumentException - if min > max
randomRotation
public static double randomRotation()
- Random angle for rotation
- Returns:
- a random number between 0 and 2 PI
Copyright © 2010. All Rights Reserved.