bubolo
 All Classes Namespaces Functions Variables Enumerator
Public Member Functions | Package Functions | List of all members
bubolo.graphics.TankCameraController Class Reference
Inheritance diagram for bubolo.graphics.TankCameraController:
bubolo.graphics.CameraController bubolo.controllers.Controller

Public Member Functions

void setCamera (Camera camera)
 
boolean hasCamera ()
 
void update (World world)
 

Package Functions

 TankCameraController (Tank tank)
 

Detailed Description

Controller that moves the camera based on the tank's position.

Author
BU CS673 - Clone Productions

Definition at line 13 of file TankCameraController.java.

Constructor & Destructor Documentation

bubolo.graphics.TankCameraController.TankCameraController ( Tank  tank)
package

Constructs a TankCameraController. Package-private because TankCameraController's are internal to the Graphics system.

Parameters
tank

Definition at line 23 of file TankCameraController.java.

Member Function Documentation

boolean bubolo.graphics.TankCameraController.hasCamera ( )

Returns true if this controller has a reference to the camera, or false otherwise.

Returns
true if this controller has a reference to the camera.

Implements bubolo.graphics.CameraController.

Definition at line 35 of file TankCameraController.java.

void bubolo.graphics.TankCameraController.setCamera ( Camera  camera)

Sets a reference to the camera. The camera must be set before calling the update method.

Parameters
camerareference to the camera.

Implements bubolo.graphics.CameraController.

Definition at line 29 of file TankCameraController.java.

void bubolo.graphics.TankCameraController.update ( World  world)

Allows the controller to perform its processing. Called once per game tick.

Parameters
worldreference to the World/Model object.

Implements bubolo.controllers.Controller.

Definition at line 41 of file TankCameraController.java.