@@ -0,0 +1,1650 @@
+package balls;%0A%0Aimport java.awt.Color;%0Aimport java.awt.Graphics;%0Aimport java.awt.event.ActionEvent;%0Aimport java.awt.event.ActionListener;%0A%0Aimport javax.swing.JPanel;%0Aimport javax.swing.Timer;%0A%0Apublic class Renderer extends JPanel implements ActionListener%7B%0A%0A%09private static final long serialVersionUID = 1L;%0A%09public static Boolean start = false;%0A%09%0A%09Timer tm = new Timer(5, this);%0A%09int posX = 0, posY = 0, posXrand = 0, posYrand = 0, velX = 2, velY = 2, randX = (int)(Math.random()*7), randY = (int)(Math.random()*7);%0A%09%0A%09public void paintComponent(Graphics g) %7B%09%09%0A%09%09%09super.paintComponent(g);%0A%09%09%09g.setColor(Color.RED);%0A%09%09%09g.fillOval(posX, 40, 30, 30);%0A%09%09%09g.setColor(Color.GREEN);%0A%09%09%09g.fillOval(100, posY, 30, 30);%0A%09%09%09g.setColor(Color.YELLOW);%0A%09%09%09g.fillOval(posXrand, posYrand, 30, 30);%0A%09%09%09tm.start();%0A%09%7D%0A%0A%09@Override%0A%09public void actionPerformed(ActionEvent e) %7B%0A%09%09%09// checks Oval 1 & 2%0A%09%09%09if (posX %3C 0 %7C%7C posX %3E BallGame.width - 30)%7B%0A%09%09%09%09velX = -velX;%0A%09%09%09%7D%0A%09%09%09if (posY %3C 0 %7C%7C posY %3E BallGame.height - 30)%7B%0A%09%09%09%09velY = -velY;%0A%09%09%09%7D%0A%09%09%09posY += velY;%0A%09%09%09posX += velX;%0A%09%09%09%0A%09%09%09// checks Oval 3%0A%09%09%09if (posXrand %3C 0 %7C%7C posXrand %3E BallGame.width - 30)%7B%0A%09%09%09%09randX = -randX;%0A%09%09%09%7D%0A%09%09%09if (posYrand %3C 0 %7C%7C posYrand %3E BallGame.height - 30)%7B%0A%09%09%09%09randY = -randY;%0A%09%09%09%7D%0A%09%09%09posYrand += randY;%0A%09%09%09posXrand += randX;%0A%09%09%09%0A%09%09%09BallGame.textArea.setText(%22Ball 1: x=%22 + (posX+15) +%22 y=40%5Cn%22 + %22Ball 2: x=100 y=%22 + (posY+15) + %22%5Cn%22 + %22Ball 3: x=%22 + (posXrand+15) + %22 y=%22 + (posYrand+15));%0A%09%09%09%0A//%09%09%09if(posXrand == posX %7C%7C posYrand == posY)%7B%0A//%09%09%09%09BallGame.textField_1.setText(%22Collision%22);%0A//%09%09%09%7D%0A//%09%09%09else%7B%0A//%09%09%09%09BallGame.textField_1.setText(%22%22);%0A//%0A//%09%09%09%7D%0A%09%09%09%0A%09%09%09repaint();%0A%09%7D%0A%0A%7D%0A

Create Renderer.java