hedgewars/uGearsHandlersMess.pas
changeset 10356 7d1044267b83
parent 10354 56bd029245fc
child 10359 744f1151c707
equal deleted inserted replaced
10355:334b5f513703 10356:7d1044267b83
   280             Gear^.X := Gear^.X + cDrownSpeed;
   280             Gear^.X := Gear^.X + cDrownSpeed;
   281         end
   281         end
   282     else
   282     else
   283         Gear^.X := Gear^.X + Gear^.dX * cDrownSpeed;
   283         Gear^.X := Gear^.X + Gear^.dX * cDrownSpeed;
   284 
   284 
   285     if cWaterLine < hwRound(Gear^.Y) + Gear^.Radius then
       
   286     else
       
   287         Gear^.Y := Gear^.Y + Gear^.dY * cDrownSpeed;
       
   288 
       
   289     // Create some bubbles (0.5% might be better but causes too few bubbles sometimes)
   285     // Create some bubbles (0.5% might be better but causes too few bubbles sometimes)
   290     if ((not SuddenDeathDmg and (WaterOpacity < $FF))
   286     if ((not SuddenDeathDmg and (WaterOpacity < $FF))
   291     or (SuddenDeathDmg and (SDWaterOpacity < $FF))) and ((GameTicks and $1F) = 0) then
   287     or (SuddenDeathDmg and (SDWaterOpacity < $FF))) and ((GameTicks and $1F) = 0) then
   292         if (Gear^.Kind = gtHedgehog) and (Random(4) = 0) then
   288         if (Gear^.Kind = gtHedgehog) and (Random(4) = 0) then
   293             AddVisualGear(hwRound(Gear^.X) - Gear^.Radius, hwRound(Gear^.Y) - Gear^.Radius, vgtBubble)
   289             AddVisualGear(hwRound(Gear^.X) - Gear^.Radius, hwRound(Gear^.Y) - Gear^.Radius, vgtBubble)