hedgewars/uGearsRender.pas
changeset 15624 adbd2bcf7159
parent 15622 237d691e5069
child 15630 c9fec197335a
equal deleted inserted replaced
15623:6c689729b745 15624:adbd2bcf7159
   313         exit;
   313         exit;
   314 
   314 
   315     // render crosshair
   315     // render crosshair
   316     if (CrosshairGear <> nil) and (Gear = CrosshairGear) then
   316     if (CrosshairGear <> nil) and (Gear = CrosshairGear) then
   317         begin
   317         begin
   318         hogLR:= 1;
   318         if (CurAmmoGear <> nil) and (CurAmmoGear^.Kind = gtBlowTorch) then
   319         if IsHogFacingLeft(Gear) then
   319             hogLR:= CurAmmoGear^.Tag
   320             hogLR:= -1;
   320         else
       
   321             begin
       
   322             hogLR:= 1;
       
   323             if IsHogFacingLeft(Gear) then
       
   324                 hogLR:= -1
       
   325             end;
   321         setTintAdd(true);
   326         setTintAdd(true);
   322         Tint(HH^.Team^.Clan^.Color shl 8 or $FF);
   327         Tint(HH^.Team^.Clan^.Color shl 8 or $FF);
   323         DrawTextureRotated(CrosshairTexture,
   328         DrawTextureRotated(CrosshairTexture,
   324                 12, 12, CrosshairX + WorldDx, CrosshairY + WorldDy, 0,
   329                 12, 12, CrosshairX + WorldDx, CrosshairY + WorldDy, 0,
   325                 hogLR * (Gear^.Angle * 180.0) / cMaxAngle);
   330                 hogLR * (Gear^.Angle * 180.0) / cMaxAngle);