Addded property to Worldmap Spawnpoint to let Tux automatically start walking (or...
[supertux.git] / src / badguy / badguy.hpp
index d5cf873..cf0adc2 100644 (file)
@@ -93,6 +93,40 @@ public:
    * during runtime. */
   bool countMe;
 
+  /**
+   * Called when hit by a fire bullet, and is_flammable() returns true
+   */
+  virtual void ignite();
+
+  /**
+   * Called to revert a badguy when is_ignited() returns true
+   */
+  virtual void extinguish();
+
+  /**
+   * Returns whether to call ignite() when a badguy gets hit by a fire bullet
+   */
+  virtual bool is_flammable() const;
+  
+  /**
+   * Returns whether this badguys is currently on fire
+   */
+  bool is_ignited() const;
+
+  /**
+   * Called when hit by an ice bullet, and is_freezable() returns true.
+   */
+  virtual void freeze();
+
+  /**
+   * Called to unfreeze the badguy.
+   */
+  virtual void unfreeze();
+
+  virtual bool is_freezable() const;
+
+  bool is_frozen() const;
+
 protected:
   enum State {
     STATE_INIT,
@@ -185,6 +219,9 @@ protected:
    */
   bool on_ground();
 
+  bool frozen;
+  bool ignited; /**< true if this badguy is currently on fire */
+
 private:
   void try_activate();