New grow and skid sounds from remaxim
[supertux.git] / src / game_object.hpp
index f463f88..7c4b59f 100644 (file)
 
 #include <string>
 #include "refcounter.hpp"
-#include "lisp/lisp.hpp"
 
 class DrawingContext;
 class ObjectRemoveListener;
 
 /**
- * This is a base class for all game objects. Each sector of a level will hold a
- * list of active GameObject while the game is played.
+ * Base class for all the things that make up Levels' Sectors.
+ *
+ * Each sector of a level will hold a list of active GameObject while the 
+ * game is played.
  *
  * This class is responsible for:
  *  - Updating and Drawing the object. This should happen in the update() and
@@ -69,14 +70,13 @@ public:
   /** registers a remove listener which will be called if the object
    * gets removed/destroyed
    */
-  void add_remove_listener(ObjectRemoveListener* listener)
-  {
-    RemoveListenerListEntry* entry = new RemoveListenerListEntry();
-    entry->next = remove_listeners;
-    entry->listener = listener;
-
-    remove_listeners = entry;
-  }
+  void add_remove_listener(ObjectRemoveListener* listener);
+  
+  /** 
+   * unregisters a remove listener, so it will no longer be called if the object
+   * gets removed/destroyed
+   */
+  void del_remove_listener(ObjectRemoveListener* listener);
 
   const std::string& get_name() const
   {