Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public void drawPaddle(Graphics2D g2) {
- g2.fillRoundRect((int) view.model.getGame().getPaddlePosition().getX(),
- (int) view.model.getGame().getPaddlePosition().getY(),
- (int) (Constants.PADDLE_WIDTH),
- (int) (Constants.PADDLE_HEIGHT),
- (int) 5,
- (int) 2);
- }
- private void drawGrid(Graphics2D g2) {
- int x;
- int y;
- for (x = 0; x < Constants.SCREEN_WIDTH; x += Constants.SCREEN_WIDTH/Constants.SQUARES_X)
- {
- g2.drawLine(x,0,x,500);
- }
- for (y = 0; y < Constants.SCREEN_HEIGHT; y += Constants.SCREEN_HEIGHT/Constants.SQUARES_Y)
- {
- g2.drawLine(0,y,600,y);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement