17 #ifndef HEADER_SUPERTUX_TRIGGER_TRIGGER_BASE_HPP 18 #define HEADER_SUPERTUX_TRIGGER_TRIGGER_BASE_HPP 22 #include "sprite/sprite_ptr.hpp" 23 #include "supertux/moving_object.hpp" 24 #include "supertux/object_remove_listener.hpp" 46 virtual void update(
float dt_sec)
override;
62 std::vector<Player*> m_losetouch_listeners;
Object came into contact.
Definition: trigger_base.hpp:36
virtual void update(float dt_sec) override
This function is called once per frame and allows the object to update it's state.
Definition: trigger_base.cpp:51
EventType
Definition: trigger_base.hpp:35
Definition: object_remove_listener.hpp:22
virtual void object_removed(GameObject *object) override
Called by GameObject destructor of an object in losetouch_listeners.
Definition: trigger_base.cpp:90
Action button pressed.
Definition: trigger_base.hpp:38
Base class for all the things that make up Levels' Sectors.
Definition: game_object.hpp:46
virtual void draw(DrawingContext &context) override
The GameObject should draw itself onto the provided DrawingContext if this function is called...
Definition: trigger_base.cpp:65
Lost contact with object.
Definition: trigger_base.hpp:37
virtual void event(Player &player, EventType type)=0
Receive trigger events.
Base class for all dynamic/moving game objects.
Definition: moving_object.hpp:31
This class is the base class for all objects you can interact with in some way.
Definition: trigger_base.hpp:31
Definition: reader_mapping.hpp:31
virtual HitResponse collision(GameObject &other, const CollisionHit &hit) override
this function is called when the object collided with any other object
Definition: trigger_base.cpp:74
Definition: player.hpp:39
This class provides functions for drawing things on screen.
Definition: drawing_context.hpp:42
This class collects data about a collision.
Definition: collision_hit.hpp:44