- moved loadshared() to the right point
[supertux.git] / src / worldmap.h
index b347bc9..71e9d26 100644 (file)
 //  along with this program; if not, write to the Free Software
 //  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
 
-#ifndef HEADER_WORLDMAP_HXX
-#define HEADER_WORLDMAP_HXX
+#ifndef SUPERTUX_WORLDMAP_H
+#define SUPERTUX_WORLDMAP_H
 
 #include <vector>
 #include <string>
 
+#include <SDL_mixer.h>
+
 namespace WorldMapNS {
 
 struct Point
@@ -44,13 +46,6 @@ struct Point
   int y;
 };
 
-struct Level
-{
-  int x;
-  int y;
-  std::string name;
-};
-
 struct Tile
 {
   texture_type sprite;
@@ -119,6 +114,9 @@ private:
   Tux* tux;
 
   texture_type level_sprite;
+  texture_type leveldot_green;
+  texture_type leveldot_red;
+
   bool quit;
 
   std::string name;
@@ -128,6 +126,13 @@ private:
   int width;
   int height;
 
+  struct Level
+  {
+    int x;
+    int y;
+    std::string name;
+  };
+
   typedef std::vector<Level> Levels;
   Levels levels;
 
@@ -155,7 +160,10 @@ public:
 
   Point get_next_tile(Point pos, Direction direction);
   Tile* at(Point pos);
-  bool path_ok(Direction direction, Point old_pos, Point* new_pos);
+
+  /** Check if it is possible to walk from \a pos into \a direction,
+      if possible, write the new position to \a new_pos */
+  bool path_ok(Direction direction, Point pos, Point* new_pos);
 };
 
 } // namespace WorldMapNS