48 explicit Level(QString _name, GLfloat _length, GLfloat _width,
QObject *_parent = 0,
Skin *_asphaltSkin = NULL);
58 explicit Level(QString _filename,
QObject *_parent = 0,
Skin *_asphaltSkin = NULL);
193 bool save(
bool *newlyCreated = 0);
200 GLvoid
draw(GLboolean simplifyForPicking);
QString getSkyboxName()
Returns the Skybox Name.
Definition: level.cpp:112
QMap< GLint, Obstacle * > getObstaclesList()
Returns the Level's Obstacles List.
Definition: level.cpp:151
GLfloat getWidth()
Returns the width of the Level.
Definition: level.cpp:87
GLint width
Definition: level.h:229
QMap< GLint, Obstacle * > tempObstaclesList
Definition: level.h:227
GLfloat gravity
Definition: level.h:230
bool isInStory
Definition: level.h:225
GLint length
Definition: level.h:228
GLvoid clearTempObstaclesList()
Clears the not saves obstacles.
Definition: level.cpp:357
~Level()
Safely destroies a Level instance.
Definition: level.cpp:48
void deleteObstacle(GLint _id)
Deletes an obstacle.
Definition: level.cpp:124
bool save(bool *newlyCreated=0)
Saves the Level in a xml form using the filename as output.
Definition: level.cpp:219
GLvoid clearObstaclesList()
Returns the number of obstacles in the level.
Definition: level.cpp:351
QString skyboxName
Definition: level.h:232
QString name
Definition: level.h:224
Skin * asphaltSkin
Definition: level.h:235
bool getIsInStory()
Returns the a variable that states if the Level is in the story.
Definition: level.cpp:77
void addObstacle(Obstacle *_obstacle)
Adds an obstacle to the Level.
Definition: level.cpp:117
GLint currentObstacleId
Definition: level.h:233
It is the Skin Class.
Definition: skin.h:30
void setName(QString _name)
Set the name of the Level.
Definition: level.cpp:72
bool isLoaded
Definition: level.h:234
void moveObstacle(GLint _id, Vector3f *newCell)
Moves an obstacle to a new position.
Definition: level.cpp:143
GLvoid setGravity(GLfloat _gravity)
Set the gravity of the Level.
Definition: level.cpp:102
void setIsInStory(bool _isInStory)
Set the a variable that states if the Level is in the story.
Definition: level.cpp:82
QString getName()
Returns the name of the Level.
Definition: level.cpp:67
Structure that rapresents a Vector of float in a 3-D space.
Definition: vector3f.h:31
QString ambientMusicFilename
Definition: level.h:231
bool load()
Loads the Level from xml form using the filename as input.
Definition: level.cpp:156
GLfloat getGravity()
Returns the gravity of the Level.
Definition: level.cpp:97
GLint getObstacleListCount()
Returns the number of obstacles in the level.
Definition: level.cpp:346
QString getFilename()
Returns the filename of the Level.
Definition: level.cpp:57
GLvoid draw(GLboolean simplifyForPicking)
Draws the Level and its obstacles.
Definition: level.cpp:318
QObject * parent
Definition: level.h:222
This class rapresents a Level of Qubet, with its obstacle. It is able to draw itself simply using the...
Definition: level.h:33
GLfloat getLength()
Returns the length of the Level.
Definition: level.cpp:92
This class rapresents an Obstacle.
Definition: obstacle.h:30
QString filename
Definition: level.h:223
QMap< GLint, Obstacle * > obstaclesList
Definition: level.h:226
QString getAmbientMusicFilename()
Returns the ambient Music Filename.
Definition: level.cpp:107
Level(QString _name, GLfloat _length, GLfloat _width, QObject *_parent=0, Skin *_asphaltSkin=NULL)
Creates a level from an id, a name, a length and a width. It is used to create a new Level from the L...
Definition: level.cpp:34
void setFilename(QString _filename)
Set the Level filename.
Definition: level.cpp:62