Cleanups related to tilemap positions:
authorflorianf <florianf@837edb03-e0f3-0310-88ca-d4d4e8b29345>
Sat, 30 Jan 2010 12:44:05 +0000 (12:44 +0000)
committerflorianf <florianf@837edb03-e0f3-0310-88ca-d4d4e8b29345>
Sat, 30 Jan 2010 12:44:05 +0000 (12:44 +0000)
commitbb423166352cd63fdf40b0f51b6699a47890faee
treeddbfa0cd80ec3816767b05eb1e105fbbb15f6f68
parent0e0a2925fc673cde72378aefedbbaec5c1a8332f
Cleanups related to tilemap positions:

- Combine TileMap::{x,y}_offset into a vector TileMap::offset.

- Factor out some widely duplicated code into new TileMap methods
  get_tile_position, get_bbox, get_tile_bbox, get_tiles_overlapping.

- AATriangle contains a Rectf instead of two vectors.

- Some simplification to Sector::is_free_of_tiles.

- BadGuy::might_fall passed a zero-width rectangle to
  Sector::is_free_of_tiles.  With the new code, such a rectangle can slip
  between two tiles without overlapping either one, giving an incorrect
  result.  So change the BadGuy::might_fall rectangle to have width 1.

Thanks to Matt McCutchen for this patch.

git-svn-id: http://supertux.lethargik.org/svn/supertux/trunk/supertux@6297 837edb03-e0f3-0310-88ca-d4d4e8b29345
src/badguy/badguy.cpp
src/math/aatriangle.hpp
src/object/particlesystem_interactive.cpp
src/object/tilemap.cpp
src/object/tilemap.hpp
src/supertux/collision.cpp
src/supertux/sector.cpp