|
CG-Project2
|
Solves all collision between entities in the given PhysicWorld. More...
#include <PhysicWorld.hpp>


Public Member Functions | |
| virtual void | solve () override |
| It gets all collisions at the current step, and calls a different method based on the collider type of the entities. To call the right method it uses the ColliderType as index of a matrix containing all tests method pointers. | |
| CollisionSolver (PhysicWorld &world) | |
| Instance basic CollisionSolver object. | |
| Public Member Functions inherited from Solver | |
| Solver (PhysicWorld &world) | |
| Instances basic Solver. | |
Additional Inherited Members | |
| Public Attributes inherited from Solver | |
| PhysicWorld & | world |
| the reference to the PhysicWorld | |
Solves all collision between entities in the given PhysicWorld.
|
inline |
Instance basic CollisionSolver object.
| world | the physic world to be attached |
|
overridevirtual |
It gets all collisions at the current step, and calls a different method based on the collider type of the entities. To call the right method it uses the ColliderType as index of a matrix containing all tests method pointers.
After testing the collisions, if the entities are colliding it applies the right modification to his position/physic values.
Reimplemented from Solver.