diff options
Diffstat (limited to 'Game/Code/Menu')
-rw-r--r-- | Game/Code/Menu/UDisplay.pas | 1 | ||||
-rw-r--r-- | Game/Code/Menu/UMenu.pas | 32 |
2 files changed, 12 insertions, 21 deletions
diff --git a/Game/Code/Menu/UDisplay.pas b/Game/Code/Menu/UDisplay.pas index 7d31e578..94a63ca9 100644 --- a/Game/Code/Menu/UDisplay.pas +++ b/Game/Code/Menu/UDisplay.pas @@ -165,7 +165,6 @@ begin // if (Screens = 2) and (S = 2) then ScreenX := 1;
ScreenX := 0;
- if S = 2 then TimeSkip := 0 else;
glViewPort((S-1) * ScreenW div Screens, 0, ScreenW div Screens, ScreenH);
//popup hack
diff --git a/Game/Code/Menu/UMenu.pas b/Game/Code/Menu/UMenu.pas index 7656c639..f33ae244 100644 --- a/Game/Code/Menu/UMenu.pas +++ b/Game/Code/Menu/UMenu.pas @@ -171,6 +171,7 @@ uses UCommon, UGraphic, UDisplay, UCovers, + UTime, USkins; destructor TMenu.Destroy; @@ -325,7 +326,10 @@ begin if ( BackImg.TexNum = 0 ) then begin if VideoPlayback.Open( fFileName ) then + begin + VideoBGTimer.SetTime(0); VideoPlayback.Play; + end; end; BackImg.W := 800; @@ -740,7 +744,6 @@ var PetX: integer; PetY: integer; begin - BackImg.ColR := 1; BackImg.ColG := 1; BackImg.ColB := 1; @@ -748,34 +751,20 @@ begin BackImg.TexY1 := 0; BackImg.TexX2 := 1; BackImg.TexY2 := 1; + if (BackImg.TexNum > 0) then begin - // does anyone know what these loops were for? - { - // draw texture with overlapping - for PetY := 1 to BackH do - for PetX := 1 to BackW do begin - BackImg.X := (PetX-1)/BackW * 800; //640 - BackImg.Y := (PetY-1)/BackH * 600; //480 - DrawTexture(BackImg); - end; // for PetX - } - { - BackImg.X:=BackW; - BackImg.Y:=BackW; - } BackImg.X := 0; BackImg.Y := 0; BackImg.Z := 0; // todo: eddie: to the opengl experts: please check this! On the mac z is not initialized??? BackImg.W := 800; BackImg.H := 600; DrawTexture(BackImg); - end; // if - - - //if assigned( VideoPlayback ) then + end + else if (VideoPlayback <> nil) then begin - VideoPlayback.GetFrame( now() ); + VideoPlayback.GetFrame(VideoBGTimer.GetTime()); + // FIXME: why do we draw on screen 2? Seems to be wrong. VideoPlayback.DrawGL(2); end; @@ -1589,7 +1578,10 @@ begin if fileexists( fFileName ) then begin if VideoPlayback.Open( fFileName ) then + begin + VideoBGTimer.SetTime(0); VideoPlayback.Play; + end; end; end; end; |