supertux
Public Member Functions | List of all members
CollisionListener Class Referenceabstract
Inheritance diagram for CollisionListener:
Inheritance graph
[legend]

Public Member Functions

virtual void collision_solid (const CollisionHit &)=0
 this function is called when the object collided with something solid
 
virtual bool collides (GameObject &, const CollisionHit &) const =0
 when 2 objects collided, we will first call the collision functions of both objects that can decide on how to react to the collision. More...
 
virtual HitResponse collision (GameObject &other, const CollisionHit &hit)=0
 this function is called when the object collided with any other object
 
virtual void collision_tile (uint32_t)=0
 called when tiles with special attributes have been touched
 
virtual bool listener_is_valid () const =0
 

Member Function Documentation

◆ collides()

virtual bool CollisionListener::collides ( GameObject ,
const CollisionHit  
) const
pure virtual

when 2 objects collided, we will first call the collision functions of both objects that can decide on how to react to the collision.

Implemented in MovingObject, TreeWillOWisp, GhostTree, MagicBlock, and InvisibleBlock.


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