share/hedgewars/Data/Scripts/Multiplayer/Racer.lua
changeset 10022 eb981a03de90
parent 9483 14ad1ac00ac9
child 10036 3be36d2fdca6
--- a/share/hedgewars/Data/Scripts/Multiplayer/Racer.lua	Sun Jan 19 17:53:16 2014 +0100
+++ b/share/hedgewars/Data/Scripts/Multiplayer/Racer.lua	Mon Jan 20 00:25:40 2014 +0400
@@ -72,6 +72,7 @@
 -----------------------------
 
 HedgewarsScriptLoad("/Scripts/Locale.lua")
+HedgewarsScriptLoad("/Scripts/OfficialChallenges.lua")
 
 ------------------
 -- Got Variables?
@@ -718,3 +719,14 @@
         end
 
 end
+
+
+function onAchievementsDeclaration()
+    map = detectMap()
+    
+    for i = 0, (numTeams-1) do
+        if teamScore[i] < 100000 then
+            DeclareAchievement("rope race", teamNameArr[i], map, teamScore[i])
+        end
+    end
+end