forked from avilanicolas/Crazy8
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathPlayer.java
45 lines (40 loc) · 1.15 KB
/
Player.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
package Crazy8;
import java.util.ArrayList;
/**
* A class that provides framework for a Player character in the Crazy 8s game.
*/
public class Player
{
/** The Player name. */
public String name = "";
/** For use at the beginning of the game, the character will have a unique line of dialogue to say. */
public String openingText = "";
/** Their greeting response to the player. */
public String greetingText = "";
/** Their taunt to the player. */
public String tauntText = "";
/** Their hand of cards. */
public ArrayList<Card> hand;
/**
* @param newName Their new name.
* @param opening Their opening line.
* @param greeting Their greeting line.
* @param taunt Their taunt response.
*/
public Player(String newName, String opening, String greeting, String taunt)
{
this.name = newName;
this.greetingText = greeting;
this.tauntText = taunt;
this.openingText = opening;
//this.hand = newHand;
}
public Player() {}
/**
* @return This player's name.
*/
public String toString()
{
return this.name;
}
}