randomSpeed method
Implementation
double randomSpeed() {
double speed = getDouble(minSpeed, maxSpeed);
double direction = rm.nextInt(2) == 0 ? -1 : 1;
return speed * direction;
}
double randomSpeed() {
double speed = getDouble(minSpeed, maxSpeed);
double direction = rm.nextInt(2) == 0 ? -1 : 1;
return speed * direction;
}