hedgewars/uGearsRender.pas
changeset 5041 3dc6ad20cbfe
parent 5039 2376d5899ff9
child 5136 948da1e50205
equal deleted inserted replaced
5040:c6cd873ac13a 5041:3dc6ad20cbfe
    19 {$INCLUDE "options.inc"}
    19 {$INCLUDE "options.inc"}
    20 
    20 
    21 unit uGearsRender;
    21 unit uGearsRender;
    22 
    22 
    23 interface
    23 interface
    24 uses uTypes, uConsts, GLunit, uFloat;
    24 uses uTypes, uConsts, GLunit, uFloat, SDLh;
    25 
    25 
    26 procedure RenderGear(Gear: PGear; x, y: LongInt);
    26 procedure RenderGear(Gear: PGear; x, y: LongInt);
    27 
    27 
    28 var RopePoints: record
    28 var RopePoints: record
    29                 Count: Longword;
    29                 Count: Longword;
  1039                     end;
  1039                     end;
  1040       gtNapalmBomb: DrawRotated(sprNapalmBomb, x, y, 0, DxDy2Angle(Gear^.dY, Gear^.dX));
  1040       gtNapalmBomb: DrawRotated(sprNapalmBomb, x, y, 0, DxDy2Angle(Gear^.dY, Gear^.dX));
  1041            gtFlake: if (Gear^.State and gstTmpFlag) <> 0 then
  1041            gtFlake: if (Gear^.State and gstTmpFlag) <> 0 then
  1042                         //DrawRotatedTextureF(SpritesData[sprSnowBall].Texture, 1, 0, 0, x, y, 0, 1, 8, 8, Gear^.DirAngle)
  1042                         //DrawRotatedTextureF(SpritesData[sprSnowBall].Texture, 1, 0, 0, x, y, 0, 1, 8, 8, Gear^.DirAngle)
  1043                         begin
  1043                         begin
  1044                         Tint(cExplosionBorderColor shl 8 or $000000FF);
  1044                         Tint((cExplosionBorderColor shr RShift) and $FF, 
       
  1045                              (cExplosionBorderColor shr GShift) and $FF, 
       
  1046                              (cExplosionBorderColor shr BShift) and $FF, 
       
  1047                              (cExplosionBorderColor shr AShift) and $FF);
  1045                         //DrawRotated(sprSnow, x, y, 0, Gear^.DirAngle);
  1048                         //DrawRotated(sprSnow, x, y, 0, Gear^.DirAngle);
  1046                         // Needs a nicer white texture to tint
  1049                         // Needs a nicer white texture to tint
  1047                         DrawTexture(x, y, SpritesData[sprVampiric].Texture, 0.1);
  1050                         DrawTexture(x, y, SpritesData[sprVampiric].Texture, 0.1);
  1048                         Tint($FF, $FF, $FF, $FF);
  1051                         Tint($FF, $FF, $FF, $FF);
  1049                         end
  1052                         end