19 #ifndef POSITIONCONTROLLER_H
20 #define POSITIONCONTROLLER_H
114 #endif // POSITIONCONTROLLER_H
QObject * parent
Definition: positioncontroller.h:63
GLint levelWidth
Definition: positioncontroller.h:67
PositionController Class check if the cube has a collision with obstacles.
Definition: positioncontroller.h:30
Vector3f * positionToCell(Vector3f *position)
Returns the cell coordinates from absolute position.
Definition: positioncontroller.cpp:103
~PositionController()
Destroy a PositionController Object.
Definition: positioncontroller.cpp:40
void stopChecking()
Stop checking for collisions.
Definition: positioncontroller.cpp:54
void startChecking()
Start checking for collision.
Definition: positioncontroller.cpp:49
QTimer * checkPositionTimer
Definition: positioncontroller.h:68
QVector< QVector< QVector< bool > > > obstacleCells
Definition: positioncontroller.h:69
void checkCollision()
Check if the cube has a collision with an obstacle.
Definition: positioncontroller.cpp:59
GLint levelLength
Definition: positioncontroller.h:66
void collision()
Signal emitted when the cube has a collision with an obstacle.
Level * level
Definition: positioncontroller.h:65
Structure that rapresents a Vector of float in a 3-D space.
Definition: vector3f.h:31
This class rapresents the player's Cube.
Definition: cube.h:31
GLvoid createObstacleCells()
Create the 3D Matrix of ObstacleCells.
Definition: positioncontroller.cpp:123
void run()
Reimplementation of the run() function of the QThread class.
Definition: positioncontroller.cpp:114
PositionController(Cube *_cube, Level *_level, QObject *_parent=0)
Create a PositionController Objects.
Definition: positioncontroller.cpp:22
This class rapresents a Level of Qubet, with its obstacle. It is able to draw itself simply using the...
Definition: level.h:33
bool isInteger(float f)
Check if a float is an integer.
Definition: positioncontroller.cpp:117
Cube * cube
Definition: positioncontroller.h:64