@ -19,6 +19,10 @@ Random random;
xDirect(randomXDirection);
int randomYDirection = random.nextInt(2);
yDirect(randomYDirection);
}
private void yDirect(int randomYDirection) {
if (randomYDirection == 0)
randomYDirection--;
setYDirection(randomYDirection * ballSpeed);