/******************************* / PuzzlePanel.java / Written by Timothy M. Bailey / Started: March 31, 1998 / Updated: April 13, 1998 / / Used for Wheel of Money applet for cs406 Dr. Webster / ********************************/ import java.awt.*; import java.applet.*; import java.lang.*; import java.net.*; public class PuzzlePanel extends Panel { Image[][] puzzle; String puzzleType; int i, j; public PuzzlePanel(Image[][] puzzle) { this.puzzle = puzzle; this.show(); } public void paint (Graphics g) { this.reshape(0, 100, 533, 300); for (i=0; i<8; i++) { for (j=0; j<15; j++) { g.drawImage(puzzle[i][j], (30*j)+40, (30*i)+15, 30, 30, this); } } g.setFont(new Font("TimesRoman", Font.BOLD, 18)); g.setColor(Color.cyan); g.drawString(puzzleType, 200, 275); this.show(); } }