-optimized and cleaned up collision_object_map
[supertux.git] / src / level.cpp
index 34a914a..cbda1f5 100644 (file)
@@ -733,7 +733,7 @@ Level::get_level_music_fast()
 }
 
 unsigned int 
-Level::gettileid(float x, float y)
+Level::gettileid(float x, float y) const
 {
   int xx, yy;
   unsigned int c;
@@ -749,4 +749,13 @@ Level::gettileid(float x, float y)
   return c;
 }
 
+unsigned int
+Level::get_tile_at(int x, int y) const
+{
+  if(x < 0 || x > width || y < 0 || y > 14)
+    return 0;
+  
+  return ia_tiles[y][x];
+}
+
 /* EOF */