17 #ifndef HEADER_SUPERTUX_OBJECT_COIN_HPP 18 #define HEADER_SUPERTUX_OBJECT_COIN_HPP 20 #include "object/path_object.hpp" 21 #include "object/moving_sprite.hpp" 22 #include "supertux/physic.hpp" 41 virtual void update(
float dt_sec)
override;
42 virtual std::string get_class()
const override {
return "coin"; }
43 virtual std::string get_display_name()
const override {
return _(
"Coin"); }
46 virtual void after_editor_set()
override;
49 virtual void move_to(
const Vector& pos)
override;
58 std::string m_collect_script;
62 Coin& operator=(
const Coin&) =
delete;
71 virtual void update(
float dt_sec)
override;
74 virtual std::string get_class()
const override {
return "heavycoin"; }
75 virtual std::string get_display_name()
const override {
return _(
"Heavy coin"); }
78 virtual void after_editor_set()
override;
A walker that travels along a path.
Definition: path_walker.hpp:29
virtual void editor_update() override
Called each frame in the editor, used to keep linked objects together (e.g.
Definition: coin.cpp:93
virtual void collision_solid(const CollisionHit &) override
this function is called when the object collided with something solid
Definition: moving_object.hpp:42
Simple two dimensional vector.
Definition: vector.hpp:24
Physics engine.
Definition: physic.hpp:27
Definition: object_settings.hpp:35
virtual HitResponse collision(GameObject &other, const CollisionHit &hit) override
this function is called when the object collided with any other object
Definition: coin.cpp:183
virtual void finish_construction() override
Called after all objects have been added to the Sector and the Sector is fully constructed.
Definition: coin.cpp:59
Base class for all the things that make up Levels' Sectors.
Definition: game_object.hpp:46
A class for all objects that contain / make use of a path.
Definition: path_object.hpp:28
This class is responsible for drawing the level tiles.
Definition: tilemap.hpp:39
Definition: reader_mapping.hpp:31
virtual void update(float dt_sec) override
This function is called once per frame and allows the object to update it's state.
Definition: coin.cpp:71
Abstract base class for MovingObjects that are represented by a Sprite.
Definition: moving_sprite.hpp:29
This class collects data about a collision.
Definition: collision_hit.hpp:44