mElite
1.0
An Elite clone based on TextElite by Jan-Philipp Kappmeier and Melanie Schmidt.
|
The main class of mElite, which is an extension of the general OpenGLApplication class. More...
#include <App.h>
Public Member Functions | |
bool | initialize (void) |
Initializing of the application. | |
void | deinitialize (void) |
De-initialises this object and frees any resources it is using. | |
void | update (DWORD milliseconds) |
Updates the game status if there is time and nothing else to do. | |
void | draw (void) |
Draws the scene. | |
GLUquadricObj * | getQuadricObject () |
void | loadAllNeededTextures () |
Loads all needed textures into the textureslots, exclusive planets. | |
void | loadSystemTextures () |
Loads textures for the current system. | |
Frustum * | getFrustum (void) |
Gets the frustum. | |
void | printInfoLine (const char *text,...) |
Prints a text. | |
Public Attributes | |
MouseHandler * | mouse |
PlayerObject * | player |
CameraObject * | cameraSystemView |
BitmapFont * | bf |
TextureFont * | tf |
TextureFont * | tf2 |
TextInput * | ti |
Console * | con |
Frustum * | frustum |
Friends | |
class | OpenGLApplication |
Additional Inherited Members | |
Private Member Functions inherited from OpenGLApplication | |
virtual | ~OpenGLApplication (void) |
OpenGLApplication (const char *className) | |
Constructs an OpenGLApplication with a given name. | |
OpenGLWindow * | getWindow (void) |
Return the window that belongs tho this application instance. | |
void | fastMode () |
Disables face culling, lighting and the depth testing. | |
void | fullMode () |
Enables face culling, lighting and the depth testing. | |
void | terminate () |
This function is called if the application quits by sending the appropriate window message and stopping the main program loop. | |
void | toggleFullscreen () |
Switches between fullscreen and windowed displaymode. | |
void | resizeDraw (bool enable) |
Enable or disable resizing while changing window size. | |
void | setFrameLimit (unsigned int framesPerSecond) |
Sets frame limit. If the computer is faster than the frame limit, it is supposed not to render again. | |
unsigned int | getFrameLimit () |
Gets frame limit. | |
FrameCounter * | getFrameCounter () |
Gets frame counter. | |
Static Private Member Functions inherited from OpenGLApplication | |
static OpenGLApplication * | create (const char *class_name) |
Create the derived application class and return a pointer to the OpenGLApplication base class. | |
The main class of mElite, which is an extension of the general OpenGLApplication class.
Contains as members all elements that are contained in the game, such as world objects and and GUI objects. Has functions to show and update them.
|
virtual |
De-initialises this object and frees any resources it is using.
Implements OpenGLApplication.
|
virtual |
Draws the scene.
If the player is dead, the end screen is shown except developer mode is active. In this case, the came continues. Mainly the function is a long switch statement for the different game modes. Then appropriate methods are called.
Implements OpenGLApplication.
Frustum * App::getFrustum | ( | void | ) |
|
virtual |
Initializing of the application.
Mainly the OpenGL-System is initialized. Objects, textures are loaded and some needed objects, e.g. for printing, are initialized. This happens everytime the window is created, that means it happens also if the application toggles between fullscreen and windowed mode.
Implements OpenGLApplication.
void App::loadAllNeededTextures | ( | ) |
void App::loadSystemTextures | ( | ) |
void App::printInfoLine | ( | const char * | inputstring, |
... | |||
) |
|
virtual |
Updates the game status if there is time and nothing else to do.
deltaTime | the time in milliseconds that has passed since the last call |
Implements OpenGLApplication.
|
friend |
BitmapFont* App::bf |
CameraObject* App::cameraSystemView |
MouseHandler* App::mouse |
PlayerObject* App::player |
TextureFont* App::tf |
TextureFont* App::tf2 |