forgot viewport resize is a thing.
authorsheepluva
Sat, 23 Jan 2016 20:58:23 +0100
changeset 11530 c27565c942f5
parent 11529 c6bae7605ea4
child 11531 743200547747
forgot viewport resize is a thing.
hedgewars/uWorld.pas
--- a/hedgewars/uWorld.pas	Sat Jan 23 19:49:55 2016 +0100
+++ b/hedgewars/uWorld.pas	Sat Jan 23 20:58:23 2016 +0100
@@ -1392,7 +1392,6 @@
         inc(CinematicSteps, Lag);
         if CinematicSteps > 300 then
         CinematicSteps:= 300;
-        CinematicBarH:= (ViewHeight * CinematicSteps) div 2048;
         end;
     end
 else if CinematicSteps > 0 then
@@ -1400,7 +1399,6 @@
     dec(CinematicSteps, Lag);
     if CinematicSteps < 0 then
         CinematicSteps:= 0;
-    CinematicBarH:= (ViewHeight * CinematicSteps) div 2048;
     end;
 
 // render black bars
@@ -1409,6 +1407,7 @@
     r.x:= ViewLeftX;
     r.w:= ViewWidth;
     r.y:= ViewTopY;
+    CinematicBarH:= (ViewHeight * CinematicSteps) div 2048;
     r.h:= CinematicBarH;
     DrawRect(r, 0, 0, 0, $FF, true);
     r.y:= ViewBottomY - r.h;