converted player to new object system
[supertux.git] / src / screen.cpp
index 52071d2..d20543f 100644 (file)
@@ -84,9 +84,10 @@ void drawgradient(Color top_clr, Color bot_clr)
 
     for(float y = 0; y < screen->h; y += 2)
       fillrect(0, (int)y, screen->w, 2,
-                     (int)(((float)(top_clr.red-bot_clr.red)/(0-screen->h)) * y + top_clr.red),
-                     (int)(((float)(top_clr.green-bot_clr.green)/(0-screen->w)) * y + top_clr.green),
-                     (int)(((float)(top_clr.blue-bot_clr.blue)/(0-screen->w)) * y + top_clr.blue), 255);
+       (int)(((float)(top_clr.red-bot_clr.red)/(0-screen->h)) * y + top_clr.red),
+       (int)(((float)(top_clr.green-bot_clr.green)/(0-screen->h)) * y + top_clr.green),
+       (int)(((float)(top_clr.blue-bot_clr.blue)/(0-screen->h)) * y + top_clr.blue),
+       255);
 /* calculates the color for each line, based in the generic equation for functions: y = mx + b */
 
 #ifndef NOOPENGL