X-Git-Url: https://git.verplant.org/?a=blobdiff_plain;f=src%2Fbadguy%2Fwalking_badguy.hpp;h=3200cb7085adfceade10993bc89f07c6d0465077;hb=8b67b0dc71efddc4b668bde525ba94d701f622ac;hp=b6a934b75487bf2a9df5705d3cda8b7cd98a8eb2;hpb=781b60522acc0f34ba4091838d12aa0db7cc9a56;p=supertux.git diff --git a/src/badguy/walking_badguy.hpp b/src/badguy/walking_badguy.hpp index b6a934b75..3200cb708 100644 --- a/src/badguy/walking_badguy.hpp +++ b/src/badguy/walking_badguy.hpp @@ -22,8 +22,10 @@ #include "badguy.hpp" +class Timer; + /** - * Baseclass for a Badguy that just walks around. + * Base class for Badguys that walk on the floor. */ class WalkingBadguy : public BadGuy { @@ -39,7 +41,7 @@ public: HitResponse collision_badguy(BadGuy& badguy, const CollisionHit& hit); void freeze(); void unfreeze(); - + float get_velocity_y() const; void set_velocity_y(float vy); @@ -50,6 +52,8 @@ protected: std::string walk_right_action; float walk_speed; int max_drop_height; /**< Maximum height of drop before we will turn around, or -1 to just drop from any ledge */ + Timer turn_around_timer; + int turn_around_counter; /**< counts number of turns since turn_around_timer was started */ }; #endif