equal
deleted
inserted
replaced
133 inc(tmp, ModifyDamage(Gear^.Hedgehog^.Effects[hePoisoned], Gear)); |
133 inc(tmp, ModifyDamage(Gear^.Hedgehog^.Effects[hePoisoned], Gear)); |
134 if (GameFlags and gfResetHealth) <> 0 then |
134 if (GameFlags and gfResetHealth) <> 0 then |
135 dec(Gear^.Hedgehog^.InitialHealth) // does not need a minimum check since <= 1 basically disables it |
135 dec(Gear^.Hedgehog^.InitialHealth) // does not need a minimum check since <= 1 basically disables it |
136 end; |
136 end; |
137 // Apply SD health decrease as soon as SD starts |
137 // Apply SD health decrease as soon as SD starts |
138 if (TotalRounds > cSuddenDTurns - 1) then |
138 if (TotalRoundsPre > cSuddenDTurns - 1) then |
139 begin |
139 begin |
140 inc(tmp, cHealthDecrease); |
140 inc(tmp, cHealthDecrease); |
141 if (GameFlags and gfResetHealth) <> 0 then |
141 if (GameFlags and gfResetHealth) <> 0 then |
142 dec(Gear^.Hedgehog^.InitialHealth, cHealthDecrease) |
142 dec(Gear^.Hedgehog^.InitialHealth, cHealthDecrease) |
143 end; |
143 end; |
317 end; |
317 end; |
318 stWater: |
318 stWater: |
319 if (not bBetweenTurns) and (not isInMultiShoot) then |
319 if (not bBetweenTurns) and (not isInMultiShoot) then |
320 begin |
320 begin |
321 // Start Sudden Death water rise in the 2nd round of Sudden Death |
321 // Start Sudden Death water rise in the 2nd round of Sudden Death |
322 if TotalRounds = cSuddenDTurns + 1 then |
322 if TotalRoundsPre = cSuddenDTurns + 1 then |
323 bWaterRising:= true; |
323 bWaterRising:= true; |
324 if bWaterRising and (cWaterRise > 0) then |
324 if bWaterRising and (cWaterRise > 0) then |
325 AddGear(0, 0, gtWaterUp, 0, _0, _0, 0)^.Tag:= cWaterRise; |
325 AddGear(0, 0, gtWaterUp, 0, _0, _0, 0)^.Tag:= cWaterRise; |
326 inc(step) |
326 inc(step) |
327 end |
327 end |
335 |
335 |
336 stHealth: |
336 stHealth: |
337 begin |
337 begin |
338 if (cWaterRise <> 0) or (cHealthDecrease <> 0) then |
338 if (cWaterRise <> 0) or (cHealthDecrease <> 0) then |
339 begin |
339 begin |
340 if (TotalRounds = cSuddenDTurns) and (not SuddenDeath) and (not isInMultiShoot) then |
340 if (TotalRoundsPre = cSuddenDTurns) and (not SuddenDeath) and (not isInMultiShoot) then |
341 StartSuddenDeath() |
341 StartSuddenDeath() |
342 else if (TotalRounds < cSuddenDTurns) and (not isInMultiShoot) then |
342 else if (TotalRoundsPre < cSuddenDTurns) and (not isInMultiShoot) then |
343 begin |
343 begin |
344 i:= cSuddenDTurns - TotalRounds; |
344 i:= cSuddenDTurns - TotalRoundsPre; |
345 s:= ansistring(inttostr(i)); |
345 s:= ansistring(inttostr(i)); |
346 if i = 1 then |
346 if i = 1 then |
347 AddCaption(trmsg[sidRoundSD], capcolDefault, capgrpGameState) |
347 AddCaption(trmsg[sidRoundSD], capcolDefault, capgrpGameState) |
348 else if (i = 2) or ((i > 0) and ((i mod 50 = 0) or ((i <= 25) and (i mod 5 = 0)))) then |
348 else if (i = 2) or ((i > 0) and ((i mod 50 = 0) or ((i <= 25) and (i mod 5 = 0)))) then |
349 AddCaption(FormatA(trmsg[sidRoundsSD], s), capcolDefault, capgrpGameState); |
349 AddCaption(FormatA(trmsg[sidRoundsSD], s), capcolDefault, capgrpGameState); |
350 end; |
350 end; |
351 end; |
351 end; |
352 if bBetweenTurns |
352 if bBetweenTurns |
353 or isInMultiShoot |
353 or isInMultiShoot |
354 or (TotalRounds = -1) then |
354 or (TotalRoundsPre = -1) then |
355 inc(step) |
355 inc(step) |
356 else |
356 else |
357 begin |
357 begin |
358 bBetweenTurns:= true; |
358 bBetweenTurns:= true; |
359 HealthMachine; |
359 HealthMachine; |