hedgewars/uWorld.pas
changeset 2287 e34b5363ae91
parent 2285 6746bda385e8
child 2288 c01b8258918d
equal deleted inserted replaced
2286:8a24e0858947 2287:e34b5363ae91
   400    end;
   400    end;
   401 
   401 
   402 // AmmoMenu
   402 // AmmoMenu
   403 if (AMxShift < 210) or bShowAmmoMenu then ShowAmmoMenu;
   403 if (AMxShift < 210) or bShowAmmoMenu then ShowAmmoMenu;
   404 
   404 
       
   405 // Cursor
       
   406 if isCursorVisible and bShowAmmoMenu then
       
   407    DrawSprite(sprArrow, CursorPoint.X, cScreenHeight - CursorPoint.Y, (RealTicks shr 6) mod 8);
       
   408 
   405 DrawChat;
   409 DrawChat;
   406 
       
   407 // Cursor
       
   408 if isCursorVisible then
       
   409    begin
       
   410    if not bShowAmmoMenu then
       
   411      with CurrentHedgehog^ do
       
   412        if (Gear^.State and gstHHChooseTarget) <> 0 then
       
   413          begin
       
   414          i:= Ammo^[CurSlot, CurAmmo].Pos;
       
   415          with Ammoz[Ammo^[CurSlot, CurAmmo].AmmoType] do
       
   416            if PosCount > 1 then
       
   417               DrawSprite(PosSprite, CursorPoint.X - SpritesData[PosSprite].Width div 2,
       
   418                                     cScreenHeight - CursorPoint.Y - SpritesData[PosSprite].Height div 2,
       
   419                                     i);
       
   420          end;
       
   421    DrawSprite(sprArrow, CursorPoint.X, cScreenHeight - CursorPoint.Y, (RealTicks shr 6) mod 8)
       
   422    end;
       
   423 
   410 
   424 if isPaused then DrawCentered(cScreenWidth div 2, cScreenHeight div 2, PauseTexture);
   411 if isPaused then DrawCentered(cScreenWidth div 2, cScreenHeight div 2, PauseTexture);
   425 
   412 
   426 inc(Frames);
   413 inc(Frames);
   427 if cShowFPS then
   414 if cShowFPS then
   454    end;
   441    end;
   455 
   442 
   456 if GameState = gsConfirm then DrawCentered(0, cScreenHeight div 2, ConfirmTexture);
   443 if GameState = gsConfirm then DrawCentered(0, cScreenHeight div 2, ConfirmTexture);
   457 
   444 
   458 SetScale(zoom);
   445 SetScale(zoom);
       
   446 
       
   447 // Cursor
       
   448 if isCursorVisible then
       
   449    begin
       
   450    if not bShowAmmoMenu then
       
   451      with CurrentHedgehog^ do
       
   452        if (Gear^.State and gstHHChooseTarget) <> 0 then
       
   453          begin
       
   454          i:= Ammo^[CurSlot, CurAmmo].Pos;
       
   455          with Ammoz[Ammo^[CurSlot, CurAmmo].AmmoType] do
       
   456            if PosCount > 1 then
       
   457               DrawSprite(PosSprite, CursorPoint.X - SpritesData[PosSprite].Width div 2,
       
   458                                     cScreenHeight - CursorPoint.Y - SpritesData[PosSprite].Height div 2,
       
   459                                     i);
       
   460          end;
       
   461    DrawSprite(sprArrow, CursorPoint.X, cScreenHeight - CursorPoint.Y, (RealTicks shr 6) mod 8)
       
   462    end;
       
   463 
   459 
   464 
   460 glDisable(GL_TEXTURE_2D);
   465 glDisable(GL_TEXTURE_2D);
   461 glDisable(GL_BLEND)
   466 glDisable(GL_BLEND)
   462 end;
   467 end;
   463 
   468