Browse Source

refactoring:

main
fdai4616 2 years ago
parent
commit
b726727bdd
  1. 6
      src/main/java/PingPong/Ball.java

6
src/main/java/PingPong/Ball.java

@ -44,7 +44,11 @@ Random random;
y += yVelocity; y += yVelocity;
} }
public void draw(Graphics g){ public void draw(Graphics g){
g.setColor(Color.red);
Color(g);
g.fillOval(x, y, width, height); g.fillOval(x, y, width, height);
} }
private static void Color(Graphics g) {
g.setColor(Color.red);
}
} }
Loading…
Cancel
Save