Current Forum: Homework 6 - Part II |
Date: Tue Dec 4 2001 11:54 am |
Author: White, David <white3@andrew.cmu.edu> |
Subject: Problem found with GUI! |
|
|
I found the problem. It is with the gui. The problem is that if the player is not a human player, the game gets the first twelve characters of the players name. My name is "Computer", only 8 characters and hence an array out of bounds exception is thrown on the following line:
p1name.setText(pb.playerName().substring(0,12));
For now I'll be: "Computer " and that seems to work fine...
|
|