equal
deleted
inserted
replaced
79 end; |
79 end; |
80 PlaySound(sndSplash); |
80 PlaySound(sndSplash); |
81 |
81 |
82 if not cReducedQuality then |
82 if not cReducedQuality then |
83 begin |
83 begin |
84 AddVisualGear(hwRound(Gear^.X), LAND_HEIGHT, vgtSplash); |
84 AddVisualGear(hwRound(Gear^.X), cWaterLine, vgtSplash); |
85 |
85 |
86 maxDrops := (Gear^.Radius div 2) + hwRound(Gear^.dX * Gear^.Radius * 2) + hwRound(Gear^.dY * Gear^.Radius * 2); |
86 maxDrops := (Gear^.Radius div 2) + hwRound(Gear^.dX * Gear^.Radius * 2) + hwRound(Gear^.dY * Gear^.Radius * 2); |
87 for i:= max(maxDrops div 3, min(32, Random(maxDrops))) downto 0 do |
87 for i:= max(maxDrops div 3, min(32, Random(maxDrops))) downto 0 do |
88 begin |
88 begin |
89 particle := AddVisualGear(hwRound(Gear^.X) - 3 + Random(6), LAND_HEIGHT, vgtDroplet); |
89 particle := AddVisualGear(hwRound(Gear^.X) - 3 + Random(6), cWaterLine, vgtDroplet); |
90 if particle <> nil then |
90 if particle <> nil then |
91 begin |
91 begin |
92 particle^.dX := particle^.dX - (Gear^.dX / 10); |
92 particle^.dX := particle^.dX - (Gear^.dX / 10); |
93 particle^.dY := particle^.dY - (Gear^.dY / 5) |
93 particle^.dY := particle^.dY - (Gear^.dY / 5) |
94 end |
94 end |
164 end; |
164 end; |
165 |
165 |
166 //////////////////////////////////////////////////////////////////////////////// |
166 //////////////////////////////////////////////////////////////////////////////// |
167 procedure doStepFallingGear(Gear: PGear); |
167 procedure doStepFallingGear(Gear: PGear); |
168 var isFalling: boolean; |
168 var isFalling: boolean; |
|
169 //tmp: QWord; |
169 tdX, tdY: hwFloat; |
170 tdX, tdY: hwFloat; |
170 collV, collH: LongInt; |
171 collV, collH: LongInt; |
171 begin |
172 begin |
172 Gear^.State:= Gear^.State and not gstCollision; |
173 Gear^.State:= Gear^.State and not gstCollision; |
173 collV:= 0; |
174 collV:= 0; |
1576 Gear^.Y:= Gear^.Y + Gear^.dY; |
1577 Gear^.Y:= Gear^.Y + Gear^.dY; |
1577 |
1578 |
1578 if (hwRound(Gear^.Y) > cWaterLine) then |
1579 if (hwRound(Gear^.Y) > cWaterLine) then |
1579 begin |
1580 begin |
1580 for i:= 0 to 3 do |
1581 for i:= 0 to 3 do |
1581 AddVisualGear(hwRound(Gear^.X) - 16 + Random(32), hwRound(Gear^.Y) - 16 + Random(16), vgtSteam); |
1582 AddVisualGear(hwRound(Gear^.X) - 16 + Random(32), cWaterLine - 16 + Random(16), vgtSteam); |
1582 PlaySound(sndVaporize); |
1583 PlaySound(sndVaporize); |
1583 DeleteGear(Gear); |
1584 DeleteGear(Gear); |
1584 exit |
1585 exit |
1585 end |
1586 end |
1586 end else begin |
1587 end else begin |