equal
deleted
inserted
replaced
1215 var i, t: LongInt; |
1215 var i, t: LongInt; |
1216 spr: TSprite; |
1216 spr: TSprite; |
1217 r: TSDL_Rect; |
1217 r: TSDL_Rect; |
1218 s: shortstring; |
1218 s: shortstring; |
1219 offsetX, offsetY, screenBottom: LongInt; |
1219 offsetX, offsetY, screenBottom: LongInt; |
1220 replicateToLeft, replicateToRight, tmp, notHiddenByCinematic: boolean; |
1220 replicateToLeft, replicateToRight, tmp, isNotHiddenByCinematic: boolean; |
1221 {$IFDEF USE_VIDEO_RECORDING} |
1221 {$IFDEF USE_VIDEO_RECORDING} |
1222 a: Byte; |
1222 a: Byte; |
1223 {$ENDIF} |
1223 {$ENDIF} |
1224 begin |
1224 begin |
1225 if WorldEdge <> weWrap then |
1225 if WorldEdge <> weWrap then |
1464 RenderWorldEdge(); |
1464 RenderWorldEdge(); |
1465 |
1465 |
1466 // This scale is used to keep the various widgets at the same dimension at all zoom levels |
1466 // This scale is used to keep the various widgets at the same dimension at all zoom levels |
1467 SetScale(cDefaultZoomLevel); |
1467 SetScale(cDefaultZoomLevel); |
1468 |
1468 |
1469 notHiddenByCinematic:= true; |
1469 isNotHiddenByCinematic:= true; |
1470 // Cinematic Mode: Determine effects and state |
1470 // Cinematic Mode: Determine effects and state |
1471 if CinematicScript or (InCinematicMode and autoCameraOn |
1471 if CinematicScript or (InCinematicMode and autoCameraOn |
1472 and ((CurrentHedgehog = nil) or CurrentHedgehog^.Team^.ExtDriven |
1472 and ((CurrentHedgehog = nil) or CurrentHedgehog^.Team^.ExtDriven |
1473 or (CurrentHedgehog^.BotLevel <> 0) or (GameType = gmtDemo))) then |
1473 or (CurrentHedgehog^.BotLevel <> 0) or (GameType = gmtDemo))) then |
1474 begin |
1474 begin |
1476 begin |
1476 begin |
1477 inc(CinematicSteps, Lag); |
1477 inc(CinematicSteps, Lag); |
1478 if CinematicSteps > 300 then |
1478 if CinematicSteps > 300 then |
1479 begin |
1479 begin |
1480 CinematicSteps:= 300; |
1480 CinematicSteps:= 300; |
1481 notHiddenByCinematic:= false; |
1481 isNotHiddenByCinematic:= false; |
1482 end; |
1482 end; |
1483 end; |
1483 end; |
1484 end |
1484 end |
1485 else if CinematicSteps > 0 then |
1485 else if CinematicSteps > 0 then |
1486 begin |
1486 begin |
1488 if CinematicSteps < 0 then |
1488 if CinematicSteps < 0 then |
1489 CinematicSteps:= 0; |
1489 CinematicSteps:= 0; |
1490 end; |
1490 end; |
1491 |
1491 |
1492 // Turn time |
1492 // Turn time |
1493 if (UIDisplay <> uiNone) and (notHiddenByCinematic) then |
1493 if (UIDisplay <> uiNone) and (isNotHiddenByCinematic) then |
1494 begin |
1494 begin |
1495 {$IFDEF USE_TOUCH_INTERFACE} |
1495 {$IFDEF USE_TOUCH_INTERFACE} |
1496 offsetX:= cScreenHeight - 13; |
1496 offsetX:= cScreenHeight - 13; |
1497 {$ELSE} |
1497 {$ELSE} |
1498 offsetX:= 48; |
1498 offsetX:= 48; |
1530 end; |
1530 end; |
1531 |
1531 |
1532 end; |
1532 end; |
1533 |
1533 |
1534 // Team bars |
1534 // Team bars |
1535 if (UIDisplay = uiAll) and (notHiddenByCinematic) then |
1535 if (UIDisplay = uiAll) and (isNotHiddenByCinematic) then |
1536 RenderTeamsHealth; |
1536 RenderTeamsHealth; |
1537 |
1537 |
1538 // Wind bar |
1538 // Wind bar |
1539 if (UIDisplay <> uiNone) and (notHiddenByCinematic) then |
1539 if (UIDisplay <> uiNone) and (isNotHiddenByCinematic) then |
1540 begin |
1540 begin |
1541 {$IFDEF USE_TOUCH_INTERFACE} |
1541 {$IFDEF USE_TOUCH_INTERFACE} |
1542 offsetX:= cScreenHeight - 13; |
1542 offsetX:= cScreenHeight - 13; |
1543 offsetY:= (cScreenWidth shr 1) + 74; |
1543 offsetY:= (cScreenWidth shr 1) + 74; |
1544 {$ELSE} |
1544 {$ELSE} |
1568 DrawSpriteFromRect(sprWindL, r, (cScreenWidth shr 1) - offsetY + 74 + WindBarWidth, cScreenHeight - offsetX + 2, 13, 0); |
1568 DrawSpriteFromRect(sprWindL, r, (cScreenWidth shr 1) - offsetY + 74 + WindBarWidth, cScreenHeight - offsetX + 2, 13, 0); |
1569 end |
1569 end |
1570 end; |
1570 end; |
1571 |
1571 |
1572 // Indicators for global effects (extra damage, low gravity) |
1572 // Indicators for global effects (extra damage, low gravity) |
1573 if (UIDisplay <> uiNone) and (notHiddenByCinematic) then |
1573 if (UIDisplay <> uiNone) and (isNotHiddenByCinematic) then |
1574 begin |
1574 begin |
1575 {$IFDEF USE_TOUCH_INTERFACE} |
1575 {$IFDEF USE_TOUCH_INTERFACE} |
1576 offsetX:= (cScreenWidth shr 1) - 95; |
1576 offsetX:= (cScreenWidth shr 1) - 95; |
1577 offsetY:= cScreenHeight - 21; |
1577 offsetY:= cScreenHeight - 21; |
1578 {$ELSE} |
1578 {$ELSE} |