# HG changeset patch # User nemo # Date 1246801451 0 # Node ID 162d8f6bca256fcfe71ef01f30da2b77e66f8dbf # Parent 4f3e7bd318414b8519589de986c76d6db84279c3 Fewer bubbles for non-breathing gears diff -r 4f3e7bd31841 -r 162d8f6bca25 hedgewars/GSHandlers.inc --- a/hedgewars/GSHandlers.inc Sun Jul 05 13:39:05 2009 +0000 +++ b/hedgewars/GSHandlers.inc Sun Jul 05 13:44:11 2009 +0000 @@ -94,7 +94,11 @@ Gear^.Y:= Gear^.Y + cDrownSpeed; if hwRound(Gear^.Y) > Gear^.Radius + cWaterLine + cVisibleWater then DeleteGear(Gear); // Create some bubbles (0.5% might be better but causes too few bubbles sometimes) -if Random(1000) < 10 then AddVisualGear(hwRound(Gear^.X) - Gear^.Radius, hwRound(Gear^.Y) - Gear^.Radius, vgtBubble); +if (GameTicks and $1F) = 0 then + if (Gear^.Kind = gtHedgehog) and (Random(4) = 0) then + AddVisualGear(hwRound(Gear^.X) - Gear^.Radius, hwRound(Gear^.Y) - Gear^.Radius, vgtBubble) + else if Random(12) = 0 then + AddVisualGear(hwRound(Gear^.X) - Gear^.Radius, hwRound(Gear^.Y) - Gear^.Radius, vgtBubble) end; ////////////////////////////////////////////////////////////////////////////////