import pgss.*;
import java.awt.*;

public class BallTest extends GraphicsWindow {
    private Ball ball;
    //PART C: private Block block;

    public BallTest() {
        ball = new Ball(50, 50, 2.0, 1.0);
        //PART C: block = new Block(80, 80, 40, 40);
    }

    public void run() {
        while(true) {
            // step ball
            ball.step(this);
            //PART C: block.bounce(ball);
            
            // draw screen
            this.clearAll();
            Graphics g = this.getGraphics();
            ball.draw(g);
            //PART B: block.draw(g);
            this.repaint();
            
            // wait 20 milliseconds to draw next frame
            Clock.sleep(20);
        }
    }

    public static void main(String[] args) {
        BallTest frame = new BallTest();
        frame.show();
        frame.run();
    }
}
