hedgewars/uVisualGears.pas
changeset 5690 f6e0c5bd8020
parent 5596 555c4fc1f3bd
child 5748 70d7f8e40f53
equal deleted inserted replaced
5689:48ef34701751 5690:f6e0c5bd8020
   227                 alpha:= 1.0;
   227                 alpha:= 1.0;
   228                 scale:= 1.0
   228                 scale:= 1.0
   229                 end;
   229                 end;
   230   vgtSmokeWhite,
   230   vgtSmokeWhite,
   231   vgtSmoke: begin
   231   vgtSmoke: begin
       
   232                 Scale:= 1.0;
   232                 dx:= 0.0002 * (random(45) + 10);
   233                 dx:= 0.0002 * (random(45) + 10);
   233                 dy:= 0.0002 * (random(45) + 10);
   234                 dy:= 0.0002 * (random(45) + 10);
   234                 if random(2) = 0 then dx := -dx;
   235                 if random(2) = 0 then dx := -dx;
   235                 Frame:= 7 - random(2);
   236                 Frame:= 7 - random(2);
   236                 FrameTicks:= cExplFrameTicks * 2;
   237                 FrameTicks:= cExplFrameTicks * 2;
   533               vgtEvilTrace: if Gear^.State < 8 then DrawSprite(sprEvilTrace, round(Gear^.X) + WorldDx, round(Gear^.Y) + WorldDy, Gear^.State);
   534               vgtEvilTrace: if Gear^.State < 8 then DrawSprite(sprEvilTrace, round(Gear^.X) + WorldDx, round(Gear^.Y) + WorldDy, Gear^.State);
   534               vgtLineTrail: DrawLine(Gear^.X, Gear^.Y, Gear^.dX, Gear^.dY, 1.0, $FF, min(Gear^.Timer, $C0), min(Gear^.Timer, $80), min(Gear^.Timer, $FF));
   535               vgtLineTrail: DrawLine(Gear^.X, Gear^.Y, Gear^.dX, Gear^.dY, 1.0, $FF, min(Gear^.Timer, $C0), min(Gear^.Timer, $80), min(Gear^.Timer, $FF));
   535           end;
   536           end;
   536           if (cReducedQuality and rqAntiBoom) = 0 then
   537           if (cReducedQuality and rqAntiBoom) = 0 then
   537               case Gear^.Kind of
   538               case Gear^.Kind of
   538                   vgtSmoke: DrawSprite(sprSmoke, round(Gear^.X) + WorldDx - 11, round(Gear^.Y) + WorldDy - 11, 7 - Gear^.Frame);
   539                   vgtSmoke: DrawTextureF(SpritesData[sprSmoke].Texture, Gear^.scale, round(Gear^.X) + WorldDx, round(Gear^.Y) + WorldDy, 7 - Gear^.Frame, 0, SpritesData[sprSmoke].Width, SpritesData[sprSmoke].Height);
   539                   vgtSmokeWhite: DrawSprite(sprSmokeWhite, round(Gear^.X) + WorldDx - 11, round(Gear^.Y) + WorldDy - 11, 7 - Gear^.Frame);
   540                   vgtSmokeWhite: DrawSprite(sprSmokeWhite, round(Gear^.X) + WorldDx - 11, round(Gear^.Y) + WorldDy - 11, 7 - Gear^.Frame);
   540                   vgtDust: if Gear^.State = 1 then
   541                   vgtDust: if Gear^.State = 1 then
   541                                DrawSprite(sprSnowDust, round(Gear^.X) + WorldDx - 11, round(Gear^.Y) + WorldDy - 11, 7 - Gear^.Frame)
   542                                DrawSprite(sprSnowDust, round(Gear^.X) + WorldDx - 11, round(Gear^.Y) + WorldDy - 11, 7 - Gear^.Frame)
   542                            else
   543                            else
   543                                DrawSprite(sprDust, round(Gear^.X) + WorldDx - 11, round(Gear^.Y) + WorldDy - 11, 7 - Gear^.Frame);
   544                                DrawSprite(sprDust, round(Gear^.X) + WorldDx - 11, round(Gear^.Y) + WorldDy - 11, 7 - Gear^.Frame);