hedgewars/uWorld.pas
changeset 4159 64e677349124
parent 4132 ca33a3737064
child 4197 dad127904958
equal deleted inserted replaced
4158:08f4627ad2b3 4159:64e677349124
   618                 begin
   618                 begin
   619                 tdx:= hwSign(Gear^.dX) * Sin(Gear^.Angle * Pi / cMaxAngle);
   619                 tdx:= hwSign(Gear^.dX) * Sin(Gear^.Angle * Pi / cMaxAngle);
   620                 tdy:= - Cos(Gear^.Angle * Pi / cMaxAngle);
   620                 tdy:= - Cos(Gear^.Angle * Pi / cMaxAngle);
   621                 for i:= (Gear^.Power * 24) div cPowerDivisor downto 0 do
   621                 for i:= (Gear^.Power * 24) div cPowerDivisor downto 0 do
   622                     DrawSprite(sprPower,
   622                     DrawSprite(sprPower,
   623                             int64(hwRound(Gear^.X)) + GetLaunchX(CurAmmoType, hwSign(Gear^.dX), Gear^.Angle) + round(WorldDx + tdx * (24 + i * 2)) - 16,
   623                             hwRound(Gear^.X) + GetLaunchX(CurAmmoType, hwSign(Gear^.dX), Gear^.Angle) + LongInt(round(WorldDx + tdx * (24 + i * 2))) - 16,
   624                             int64(hwRound(Gear^.Y)) + GetLaunchY(CurAmmoType, Gear^.Angle) + round(WorldDy + tdy * (24 + i * 2)) - 16,
   624                             hwRound(Gear^.Y) + GetLaunchY(CurAmmoType, Gear^.Angle) + LongInt(round(WorldDy + tdy * (24 + i * 2))) - 16,
   625                             i)
   625                             i)
   626                 end
   626                 end
   627         end;
   627         end;
   628 
   628 
   629     DrawVisualGears(1);
   629     DrawVisualGears(1);