MAK RTIspy API Documentation for HLA 1516
Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes | Static Private Attributes
controllers.KeyboardShipController Class Reference

The Class KeyboardShipController. More...

+ Inheritance diagram for controllers.KeyboardShipController:
+ Collaboration diagram for controllers.KeyboardShipController:

List of all members.

Public Member Functions

 KeyboardShipController (IMakShooterRTI myRti, Board board, final Ship ship)
 Instantiates a new keyboard ship controller.
void shipActionPressed (KeyEvent evt)
 Ship action pressed.
void shipActionReleased (KeyEvent evt)
 Ship action released.
void moveShip (int x, int y)
 Move ship.
void shoot ()
 Shoot.
void TestShoot (Ship ship)
 Purely for Testing.
void run ()
 This will start the keyboard Controller, allowing you to move one ship up and down using the UP Arrow and DOWN Arrow keys.
IShipController start ()

Protected Member Functions

void formKeyPressed (KeyEvent evt)
 Form key pressed.
void formKeyReleased (KeyEvent evt)
 Form key released.

Private Member Functions

void repaint ()
 Repaint.

Private Attributes

boolean moveUp = false
 The move up.
boolean moveDown = false
 The move down.
final Ship ship
 The ship.
final Board board
 The board.
boolean shotCooldownActive = false
Timer timer

Static Private Attributes

static final int SHOT_COOLDOWN = 500
static final int DELAY = 70
 The Constant DELAY.

Detailed Description

The Class KeyboardShipController.

Author:
snandi

Constructor & Destructor Documentation


Member Function Documentation

void controllers.KeyboardShipController.formKeyPressed ( KeyEvent  evt) [inline, protected]
void controllers.KeyboardShipController.formKeyReleased ( KeyEvent  evt) [inline, protected]
void controllers.KeyboardShipController.moveShip ( int  x,
int  y 
) [inline, virtual]
void controllers.KeyboardShipController.repaint ( ) [inline, private]
void controllers.KeyboardShipController.shoot ( ) [inline, virtual]

Member Data Documentation

final int controllers.KeyboardShipController.DELAY = 70 [static, private]

The Constant DELAY.

Referenced by controllers.KeyboardShipController.run().

boolean controllers.KeyboardShipController.moveUp = false [private]
final int controllers.KeyboardShipController.SHOT_COOLDOWN = 500 [static, private]

The documentation for this class was generated from the following file:

Document ID: Generated on Thu Jun 14 14:15:04 EDT 2012 from SVN revision 116116
Copyright © 2005-2012 VT MÄK Inc. All Rights Reserved (www.mak.com)