Update of /cvsroot/super-tux/supertux/src
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv3465/src
Modified Files:
level.cpp
Log Message:
I think this fixes image background scrolling.
Still needs testing.
Index: level.cpp
===================================================================
RCS file: /cvsroot/super-tux/supertux/src/level.cpp,v
retrieving revision 1.77
retrieving revision 1.78
diff -u -d -r1.77 -r1.78
--- level.cpp 17 May 2004 17:01:21 -0000 1.77
+++ level.cpp 18 May 2004 14:03:53 -0000 1.78
@@ -768,7 +768,7 @@
for (int x = 0; (x-1)*img_bkgd->w <= screen->w; x++)
for (int y = 0; (y-1)*img_bkgd->h <= screen->h; y++)
img_bkgd->draw_part(x == 0 ? sx : 0, y == 0 ? sy : 0,
- x == 0 ? 0 : (img_bkgd->w * x) - sx, y == 0 ? 0 : (img_bkgd->h * y) - sy + (height*32 - screen->h),
+ x == 0 ? 0 : (img_bkgd->w * x) - sx, y == 0 ? 0 : (img_bkgd->h * y) - sy,
x == 0 ? img_bkgd->w - sx : img_bkgd->w, y == 0 ? img_bkgd->h - sy : img_bkgd->h);
}
|