16 #ifndef HEADER_SUPERTUX_OBJECT_RUBLIGHT_HPP 17 #define HEADER_SUPERTUX_OBJECT_RUBLIGHT_HPP 19 #include "object/moving_sprite.hpp" 20 #include "sprite/sprite_ptr.hpp" 21 #include "video/color.hpp" 30 virtual void update(
float dt_sec)
override;
32 static std::string class_name() {
return "rublight"; }
33 virtual std::string get_class_name()
const override {
return class_name(); }
34 static std::string display_name() {
return _(
"Rublight"); }
39 virtual void on_flip(
float height)
override;
53 float strength_multiplier;
56 void rub(
float strength);
57 float get_brightness()
const;
virtual std::string get_display_name() const override
Returns the display name of the object, translated to the user's locale.
Definition: rublight.hpp:35
virtual GameObjectClasses get_class_types() const override
List notable classes in inheritance hierarchy of class.
Definition: rublight.hpp:36
Definition: object_settings.hpp:39
virtual HitResponse collision(GameObject &other, const CollisionHit &hit) override
this function is called when the object collided with any other object
Definition: rublight.cpp:66
A triboluminescent (or something similar) block.
Definition: rublight.hpp:24
virtual void on_flip(float height) override
When level is flipped vertically.
Definition: rublight.cpp:150
virtual GameObjectClasses get_class_types() const override
List notable classes in inheritance hierarchy of class.
Definition: moving_sprite.hpp:60
This class is responsible for: Updating and drawing the object.
Definition: game_object.hpp:83
virtual void update(float dt_sec) override
This function is called once per frame and allows the object to update it's state.
Definition: rublight.cpp:106
A helper structure to list all the type_indexes of the classes in the type hierarchy of a given class...
Definition: game_object.hpp:57
virtual void draw(DrawingContext &context) override
The GameObject should draw itself onto the provided DrawingContext if this function is called...
Definition: rublight.cpp:136
Definition: reader_mapping.hpp:32
Abstract base class for ""MovingObject""s, that are represented by a sprite.
Definition: moving_sprite.hpp:33
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