home *** CD-ROM | disk | FTP | other *** search
- #ifndef CREATURE_H
- #define CREATURE_H
-
- #include "Position.h"
- #include <String.hpp>
- class Level;
-
- class Creature
- {
- public:
- explicit Creature(Level * level)
- : level( level )
- {}
- virtual ~Creature()
- {}
-
- virtual void life_cycle(float delta_time) =0;
- virtual String get_name()const =0;
- virtual float get_size()const =0;
- virtual void process_collision(const Creature * cre) =0;
- virtual bool is_solid()const =0;
- virtual void process_death(const Creature * cre) =0;
- virtual bool is_alive()const =0;
- Position get_position()const
- {
- return pos;
- }
- protected:
- friend class Level;
- Position pos;
- float speed; //Γ Ωδσ≥ε≈Ωα⌡ Γ ±σΩ≤φΣ≤
- Level * level;
- };
- #endif //CREATURE_H