public class KlingonBattleCruiser {
Color c; int x,y; KlingonBattleCruiser(Color startColor) { c = startColor; } public void move(int newx, int newy) { x = newx; y = newy; } public void paint(Graphics q) { // stuff to draw the cewl battle cruiser thing } public void setColor(Color c) { // code to change the color } } |
class KlingonLoveSongs {
int songNum; KlingonLoveSongs() { // code to get the player ready goes here } public void playSong(char s) { // code to stop playing the song goes here } } |