- virtual void collision(const MovingObject& other_object,
- int collision_type) = 0;
-
- base_type base;
- base_type old_base;
-
+ virtual HitResponse collision(GameObject& other,
+ const CollisionHit& hit) = 0;
+
+ const Vector& get_pos() const
+ {
+ return bbox.p1;
+ }
+
+ /** returns the bounding box of the Object */
+ const Rectangle& get_bbox() const
+ {
+ return bbox;
+ }
+
+ const Vector& get_movement() const
+ {
+ return movement;
+ }
+
+ /** places the moving object at a specific position. Be carefull when
+ * using this function. There are no collision detection checks performed
+ * here so bad things could happen.
+ */
+ virtual void set_pos(const Vector& pos)
+ {
+ bbox.set_pos(pos);
+ }
+