public class MovesYearOfPlentyCommand extends MovesCommand
Modifier and Type | Field and Description |
---|---|
private GameModel |
gm |
private ResourceType |
resource1 |
private ResourceType |
resource2 |
playerIndex
gameID, playerID
Constructor and Description |
---|
MovesYearOfPlentyCommand(NetworkCookie cookie,
int playerIndex,
ResourceType resource1,
ResourceType resource2)
Creates a command object that plays the Year of Plenty card.
|
Modifier and Type | Method and Description |
---|---|
boolean |
Execute()
Executes a command
|
java.lang.String |
GetHeader()
Gets the new server header associated with the request.
|
java.lang.String |
GetResponse()
Gets the response for the server.
|
boolean |
Unexecute()
Unexecutes a command.
|
private ResourceType resource1
private ResourceType resource2
private GameModel gm
public MovesYearOfPlentyCommand(NetworkCookie cookie, int playerIndex, ResourceType resource1, ResourceType resource2)
playerID
- The player ID.playerIndex
- The Player index.resource1
- The resource type of card 1.resource2
- The resource type of card 2.public boolean Execute()
ICommand
public boolean Unexecute()
ICommand
public java.lang.String GetResponse()
ICommand
public java.lang.String GetHeader()
ICommand