- changed scroll speed for background image (should be configurable via level file)
authorIngo Ruhnke <grumbel@gmx.de>
Fri, 16 Apr 2004 14:50:41 +0000 (14:50 +0000)
committerIngo Ruhnke <grumbel@gmx.de>
Fri, 16 Apr 2004 14:50:41 +0000 (14:50 +0000)
- fixed bug that caused background to not get cleanly redrawn

SVN-Revision: 531

src/world.cpp

index 29f63ee..f246c36 100644 (file)
@@ -128,7 +128,7 @@ World::draw()
   /* Draw the real background */
   if(get_level()->bkgd_image[0] != '\0')
     {
-      int s = (int)scroll_x / 30;
+      int s = ((int)scroll_x / 2)%640;
       level->img_bkgd->draw_part(s, 0,0,0,level->img_bkgd->w - s, level->img_bkgd->h);
       level->img_bkgd->draw_part(0, 0,screen->w - s ,0,s,level->img_bkgd->h);
     }