- fixed problem with asyncron blinkig bonus block
[supertux.git] / src / collision.h
index 410e2e8..deee4b8 100644 (file)
@@ -14,6 +14,9 @@
 
 #include "type.h"
 
+class Tile;
+class World;
+
 /* Collision objects */
 enum
 {
@@ -25,17 +28,23 @@ enum
 enum CollisionType {
     COLLISION_NORMAL,
     COLLISION_BUMP,
-    COLLISION_SQUICH
+    COLLISION_SQUISH
 };
 
 bool rectcollision(base_type* one, base_type* two);
 bool rectcollision_offset(base_type* one, base_type* two, float off_x, float off_y);
+
 void collision_swept_object_map(base_type* old, base_type* current);
 bool collision_object_map(base_type* object);
 
-/* Checks for all possible collisions.
-   And calls the collision_handlers, which the collision_objects provide for this case (or not). */
-void collision_handler();
+/** Return a pointer to the tile at the given x/y coordinates */
+Tile* gettile(float x, float y);
+
+// Some little helper function to check for tile properties
+bool  issolid(float x, float y);
+bool  isbrick(float x, float y);
+bool  isice(float x, float y);
+bool  isfullbox(float x, float y);
 
 #endif /*SUPERTUX_COLLISION_H*/