|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object jaige.Player
public class Player
This class is used to represent a player in the Jaige games. By itself, it represents a human player. The AI class extends Player, and is used to represent AI's.
Copyright (c) Jaige 2007
Constructor Summary | |
---|---|
Player()
Creates a player with the default name "No name" and the default color of Color.RED. |
|
Player(java.lang.String name,
java.awt.Color color)
Creates a player with the specified name and color. |
Method Summary | |
---|---|
java.awt.Color |
getColor()
Gets the color of this player. |
java.lang.String |
getName()
Returns the name of this Player. |
Orientation |
getOrientation()
Gets the orientation of this player. |
void |
setColor(java.awt.Color color)
Sets the color of this player. |
void |
setName(java.lang.String name)
Sets the name of this player. |
void |
setOrientation(Orientation orientation)
Sets the orientation of this player. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Player()
public Player(java.lang.String name, java.awt.Color color)
name
- String The name of this Player.color
- Color The desired color of this player. @see setColorsetColor
Method Detail |
---|
public java.lang.String getName()
public void setName(java.lang.String name)
name
- String The new name of this player.public java.awt.Color getColor()
public void setColor(java.awt.Color color)
color
- Color The new color of this Player.public Orientation getOrientation()
Orientation
public void setOrientation(Orientation orientation)
orientation
- Orientation
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |