public class Ball
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
private int |
x
The x axis position of the ball.
|
private int |
xSpeed
The speed of the ball on the x axis.
|
private int |
y
The y axis position of the ball.
|
private int |
ySpeed
The speed of the ball on the y axis.
|
Constructor and Description |
---|
Ball()
Initializes the Ball to have position zero and velocity of 0;
|
Modifier and Type | Method and Description |
---|---|
void |
update()
Updates the physics of the ball.
|