Script parameter to adjust winning score for Mutant
authorunC0Rr
Mon, 16 Mar 2015 11:12:18 +0300
changeset 10857 6ef0fb6cd3bb
parent 10856 d080b8d4c114
child 10858 bd281e854e02
Script parameter to adjust winning score for Mutant
share/hedgewars/Data/Scripts/Multiplayer/Mutant.lua
--- a/share/hedgewars/Data/Scripts/Multiplayer/Mutant.lua	Sun Mar 15 22:01:10 2015 -0400
+++ b/share/hedgewars/Data/Scripts/Multiplayer/Mutant.lua	Mon Mar 16 11:12:18 2015 +0300
@@ -21,6 +21,7 @@
 
 HedgewarsScriptLoad("/Scripts/Locale.lua")
 HedgewarsScriptLoad("/Scripts/Tracker.lua")
+HedgewarsScriptLoad("/Scripts/Params.lua")
 
 --[[
     MUTANT SCRIPT
@@ -607,6 +608,11 @@
     end
 end
 
+function onParameters()
+    parseParams()
+    winScore = tonumber(params["winscore"]) or winScore
+end
+
 --[[
 S T A R R I N G
     prof - Coding, implementing and evangelism