cs1705.adventure
Class QuitCommand
java.lang.Object
cs1705.adventure.Command
cs1705.adventure.QuitCommand
- public class QuitCommand
- extends Command
Implementation of the 'quit' user command for adventure games.
- Version:
- 1.0 (December 2002)
- Author:
- Michael Kolling
|
Constructor Summary |
QuitCommand()
Constructor for objects of class QuitCommand |
|
Method Summary |
boolean |
execute(Player player)
"Quit" was entered. |
QuitCommand
public QuitCommand()
- Constructor for objects of class QuitCommand
execute
public boolean execute(Player player)
- "Quit" was entered. Check the argument to see whether
we really quit the game. Return true, if we should quit, false
otherwise.
- Specified by:
execute in class Command
- Returns:
- True, if game should exit; false otherwise.