// import libraries public class Ball { // declare any useful constants // declare instance variables (position, velocity, graphics "home", etc.) public Ball(Graphics g, ...) { // fill in slots using parameters (WATCH FOR NAME CONFLICTS!) } public void draw() { // set current color and fill the oval (both relative to graphics) } public void move() { // add forces to velocities // add velocities to positions // check for special conditions (bounce, etc.) using position // and update as necessary (e.g., by "reflecting" velocity) } } // class Ball