share/hedgewars/Data/Scripts/Multiplayer/Racer.lua
changeset 10044 33e64afccd3b
parent 10017 de822cd3df3a
child 10227 0b848d595f22
equal deleted inserted replaced
10043:ca075f0f7cfb 10044:33e64afccd3b
    70 -----------------------------
    70 -----------------------------
    71 -- SCRIPT BEGINS
    71 -- SCRIPT BEGINS
    72 -----------------------------
    72 -----------------------------
    73 
    73 
    74 HedgewarsScriptLoad("/Scripts/Locale.lua")
    74 HedgewarsScriptLoad("/Scripts/Locale.lua")
       
    75 HedgewarsScriptLoad("/Scripts/OfficialChallenges.lua")
    75 
    76 
    76 ------------------
    77 ------------------
    77 -- Got Variables?
    78 -- Got Variables?
    78 ------------------
    79 ------------------
    79 
    80 
   478 ----------------------------------
   479 ----------------------------------
   479 -- GAME METHODS / EVENT HANDLERS
   480 -- GAME METHODS / EVENT HANDLERS
   480 ----------------------------------
   481 ----------------------------------
   481 
   482 
   482 function onGameInit()
   483 function onGameInit()
   483         GameFlags = bor(GameFlags,gfInfAttack + gfInvulnerable)
   484         EnableGameFlags(gfInfAttack, gfInvulnerable)
   484         CaseFreq = 0
   485         CaseFreq = 0
   485         TurnTime = 90000
   486         TurnTime = 90000
   486         WaterRise = 0
   487         WaterRise = 0
   487 end
   488 end
   488 
   489 
   716         if GetGearType(gear) == gtAirAttack then
   717         if GetGearType(gear) == gtAirAttack then
   717                 cGear = nil
   718                 cGear = nil
   718         end
   719         end
   719 
   720 
   720 end
   721 end
       
   722 
       
   723 
       
   724 function onAchievementsDeclaration()
       
   725     map = detectMap()
       
   726     
       
   727     for i = 0, (numTeams-1) do
       
   728         if teamScore[i] < 100000 then
       
   729             DeclareAchievement("rope race", teamNameArr[i], map, teamScore[i])
       
   730         end
       
   731     end
       
   732 end