equal
deleted
inserted
replaced
29 procedure ResetWorldTex; |
29 procedure ResetWorldTex; |
30 |
30 |
31 procedure DrawWorld(Lag: LongInt); |
31 procedure DrawWorld(Lag: LongInt); |
32 procedure DrawWorldStereo(Lag: LongInt; RM: TRenderMode); |
32 procedure DrawWorldStereo(Lag: LongInt; RM: TRenderMode); |
33 procedure ShowMission(caption, subcaption, text: ansistring; icon, time : LongInt); |
33 procedure ShowMission(caption, subcaption, text: ansistring; icon, time : LongInt); |
|
34 procedure ShowMission(caption, subcaption, text: ansistring; icon, time : LongInt; forceDisplay : boolean); |
34 procedure HideMission; |
35 procedure HideMission; |
35 procedure SetAmmoTexts(ammoType: TAmmoType; name: ansistring; caption: ansistring; description: ansistring; autoLabels: boolean); |
36 procedure SetAmmoTexts(ammoType: TAmmoType; name: ansistring; caption: ansistring; description: ansistring; autoLabels: boolean); |
36 procedure ShakeCamera(amount: LongInt); |
37 procedure ShakeCamera(amount: LongInt); |
37 procedure InitCameraBorders; |
38 procedure InitCameraBorders; |
38 procedure InitTouchInterface; |
39 procedure InitTouchInterface; |
1604 if missionTimer < 0 then |
1605 if missionTimer < 0 then |
1605 missionTimer:= 0; // avoid subtracting below 0 |
1606 missionTimer:= 0; // avoid subtracting below 0 |
1606 if missionTex <> nil then |
1607 if missionTex <> nil then |
1607 DrawTextureCentered(0, Min((cScreenHeight shr 1) + 100, cScreenHeight - 48 - missionTex^.h), missionTex); |
1608 DrawTextureCentered(0, Min((cScreenHeight shr 1) + 100, cScreenHeight - 48 - missionTex^.h), missionTex); |
1608 end; |
1609 end; |
|
1610 if missionTimer = 0 then |
|
1611 isForceMission := false; |
1609 |
1612 |
1610 // fps |
1613 // fps |
1611 {$IFDEF USE_TOUCH_INTERFACE} |
1614 {$IFDEF USE_TOUCH_INTERFACE} |
1612 offsetX:= pauseButton.frame.y + pauseButton.frame.h + 12; |
1615 offsetX:= pauseButton.frame.y + pauseButton.frame.h + 12; |
1613 {$ELSE} |
1616 {$ELSE} |
1939 if WorldDx > 1024 then |
1942 if WorldDx > 1024 then |
1940 WorldDx:= 1024; |
1943 WorldDx:= 1024; |
1941 end; |
1944 end; |
1942 |
1945 |
1943 procedure ShowMission(caption, subcaption, text: ansistring; icon, time : LongInt); |
1946 procedure ShowMission(caption, subcaption, text: ansistring; icon, time : LongInt); |
|
1947 begin |
|
1948 ShowMission(caption, subcaption, text, icon, time, false); |
|
1949 end; |
|
1950 |
|
1951 procedure ShowMission(caption, subcaption, text: ansistring; icon, time : LongInt; forceDisplay : boolean); |
1944 var r: TSDL_Rect; |
1952 var r: TSDL_Rect; |
1945 begin |
1953 begin |
1946 if cOnlyStats then exit; |
1954 if cOnlyStats then exit; |
1947 |
1955 |
1948 r.w:= 32; |
1956 r.w:= 32; |
1949 r.h:= 32; |
1957 r.h:= 32; |
|
1958 |
|
1959 // If true, then mission panel cannot be hidden by releasing the mission panel key. |
|
1960 // Is in effect until timer runs out, is hidden with HideMission or ShowMission is called with forceDisplay=false. |
|
1961 isForceMission := forceDisplay; |
1950 |
1962 |
1951 if time = 0 then |
1963 if time = 0 then |
1952 time:= 5000; |
1964 time:= 5000; |
1953 missionTimer:= time; |
1965 missionTimer:= time; |
1954 FreeAndNilTexture(missionTex); |
1966 FreeAndNilTexture(missionTex); |
1968 end; |
1980 end; |
1969 |
1981 |
1970 procedure HideMission; |
1982 procedure HideMission; |
1971 begin |
1983 begin |
1972 missionTimer:= 0; |
1984 missionTimer:= 0; |
|
1985 isForceMission:= false; |
1973 end; |
1986 end; |
1974 |
1987 |
1975 procedure SetAmmoTexts(ammoType: TAmmoType; name: ansistring; caption: ansistring; description: ansistring; autoLabels: boolean); |
1988 procedure SetAmmoTexts(ammoType: TAmmoType; name: ansistring; caption: ansistring; description: ansistring; autoLabels: boolean); |
1976 var |
1989 var |
1977 ammoStrId: TAmmoStrId; |
1990 ammoStrId: TAmmoStrId; |