From 1ddeacb83033823ef6153292e140045ae6f13e73 Mon Sep 17 00:00:00 2001 From: florianf Date: Sun, 31 Jan 2010 22:44:17 +0000 Subject: [PATCH] src/supertux/sector.cpp: Use shift delta when checking the position of non-sloped unisolid tiles. This solves the "Tux falls through unisolid moving platforms" bug observed by Mathnerd314. git-svn-id: http://supertux.lethargik.org/svn/supertux/trunk/supertux@6302 837edb03-e0f3-0310-88ca-d4d4e8b29345 --- src/supertux/sector.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/supertux/sector.cpp b/src/supertux/sector.cpp index 27bb93920..a4f4c4792 100644 --- a/src/supertux/sector.cpp +++ b/src/supertux/sector.cpp @@ -1101,7 +1101,7 @@ int check_position_unisolid (const Rectf& obj_bbox, /* If this is not a slope, this is - again - easy */ if ((tile->getAttributes() & Tile::SLOPE) == 0) { - if (obj_bbox.get_bottom () <= tile_bbox.get_top ()) + if ((obj_bbox.get_bottom () - SHIFT_DELTA) <= tile_bbox.get_top ()) return POS_SOLID; else return POS_NON_SOLID; -- 2.11.0