Labyrinth
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends
Classes | Public Types | Public Member Functions | Protected Attributes | List of all members
LxS::Game::Path Class Reference

class representing calculated movement path for a character More...

#include <path.hpp>

Inheritance diagram for LxS::Game::Path:
Inheritance graph
Collaboration diagram for LxS::Game::Path:
Collaboration graph

Public Types

enum  Rendermode { ForReal, ForCoords3D, ForCoordsGame }
 purpose of rendering. ForReal is "to display", ForCoords3D is "to determine where user has clicked" More...
 

Public Member Functions

 Path (Map *m)
 construct path within map m
 
virtual void Initialize ()
 set up resources. (this is to facilitate late (delayed) initialization.
 
virtual void Render (Rendermode mode)
 render something
 
virtual void UnloadResources ()
 free up consumed resources while (possibly temporarily) object is not critical
 
virtual void Animate (float dt)
 move contents dt=delta time in seconds since last call to animate;
 
virtual unsigned long GetTexelsCount ()
 sum of dimensionsxdepths of all textures
 
virtual unsigned long GetFacesCount ()
 all 3D faces
 
void SetStart (float x, float y, float z)
 set starting point
 
void SetEnd (float x, float y, float z)
 set ending point
 
float GetRemainingLength ()
 distance remaining to be traversed
 
void Progress (float ds)
 move by distance given
 
float GetX ()
 get current position - X
 
float GetY ()
 get current position - Y
 
float GetZ ()
 get current position - Z
 
float GetNDX ()
 get current normalized direction - X
 
float GetNDY ()
 get current normalized direction - Y
 
float GetNDZ ()
 get current normalized direction - Z
 
float GetInitializedPercentage ()
 0= uninitialized; 100=ready; other? for progress bars
 
virtual void RefreshAssets ()
 To facilitate refreshing app after switching OpenGL Context (as in Android lifecycle)
 

Protected Attributes

float initialized_percentage
 0-100; 0- just constructed; 100 - redy to render; 0-100 - for progressbar
 

Detailed Description

class representing calculated movement path for a character

Member Enumeration Documentation

purpose of rendering. ForReal is "to display", ForCoords3D is "to determine where user has clicked"

Enumerator
ForReal 

proper rendering for display

ForCoords3D 

rendering for coordinate detection

ForCoordsGame 

for detection of ingame coordinate system - unused


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