equal
deleted
inserted
replaced
432 string.format(loc("Rounds complete: %d/%d"), roundNumber, roundLimit) .. "|" .. " " .. "|" .. |
432 string.format(loc("Rounds complete: %d/%d"), roundNumber, roundLimit) .. "|" .. " " .. "|" .. |
433 loc("Best team times: ") .. "|" .. totalComment, 0, 4000) |
433 loc("Best team times: ") .. "|" .. totalComment, 0, 4000) |
434 |
434 |
435 -- end game if its at round limit |
435 -- end game if its at round limit |
436 if roundNumber >= roundLimit then |
436 if roundNumber >= roundLimit then |
437 gameOver = true |
|
438 TurnTimeLeft = 10000000 |
|
439 |
|
440 -- Sort the scores for the ranking list |
437 -- Sort the scores for the ranking list |
441 local unfinishedArray = {} |
438 local unfinishedArray = {} |
442 local sortedTeams = {} |
439 local sortedTeams = {} |
443 local k = 1 |
440 local k = 1 |
444 for i = 0, TeamsCount-1 do |
441 for i = 0, TeamsCount-1 do |
471 SendStat(siGameResult, loc("Round draw")) |
468 SendStat(siGameResult, loc("Round draw")) |
472 SendStat(siCustomAchievement, loc("Nobody managed to finish the race. What a shame!")) |
469 SendStat(siCustomAchievement, loc("Nobody managed to finish the race. What a shame!")) |
473 SendStat(siCustomAchievement, loc("Maybe you should try easier waypoints next time.")) |
470 SendStat(siCustomAchievement, loc("Maybe you should try easier waypoints next time.")) |
474 end |
471 end |
475 |
472 |
476 -- Game over |
473 -- Kill all the losers |
477 EndGame() |
474 for i = 0, (numhhs-1) do |
|
475 if GetHogClan(hhs[i]) ~= bestClan then |
|
476 SetEffect(hhs[i], heResurrectable, 0) |
|
477 SetHealth(hhs[i],0) |
|
478 end |
|
479 end |
|
480 |
|
481 gameOver = true |
|
482 EndTurn(true) |
|
483 |
478 end |
484 end |
479 |
485 |
480 end |
486 end |
481 |
487 |
482 function CheckForNewRound() |
488 function CheckForNewRound() |
546 |
552 |
547 end |
553 end |
548 |
554 |
549 |
555 |
550 function onGameStart() |
556 function onGameStart() |
|
557 SendGameResultOff() |
|
558 SendRankingStatsOff() |
551 SendHealthStatsOff() |
559 SendHealthStatsOff() |
|
560 SendAchievementsStatsOff() |
552 |
561 |
553 roundN = 0 |
562 roundN = 0 |
554 lastRound = TotalRounds |
563 lastRound = TotalRounds |
555 RoundHasChanged = false |
564 RoundHasChanged = false |
556 |
565 |