diff --git a/[gamemodes]/[deathmatch]/deathmatch/server/main.lua b/[gamemodes]/[deathmatch]/deathmatch/server/main.lua index 9fbab16f1..63d124198 100644 --- a/[gamemodes]/[deathmatch]/deathmatch/server/main.lua +++ b/[gamemodes]/[deathmatch]/deathmatch/server/main.lua @@ -37,10 +37,10 @@ addEventHandler("onGamemodeStop", resourceRoot, stopGamemode) -- -- startGamemodeMap: initializes a gamemode map -- -local function startGamemodeMap(resource) +local function startGamemodeMap(mapResource) -- load map settings - _mapResource = resource - local resourceName = getResourceName(resource) + _mapResource = mapResource + local resourceName = getResourceName(mapResource) _fragLimit = tonumber(get(resourceName..".frag_limit")) and math.floor(tonumber(get(resourceName..".frag_limit"))) or defaults.fragLimit _timeLimit = (tonumber(get(resourceName..".time_limit")) and math.floor(tonumber(get(resourceName..".time_limit"))) or defaults.timeLimit)*1000 _respawnTime = (tonumber(get(resourceName..".respawn_time")) and math.floor(tonumber(get(resourceName..".respawn_time"))) or defaults.respawnTime)*1000 @@ -60,11 +60,11 @@ local function startGamemodeMap(resource) end end -- if the map title is not defined in the map's meta.xml, use the resource name - _mapTitle = getResourceInfo(resource, "name") + _mapTitle = getResourceInfo(mapResource, "name") if not _mapTitle then _mapTitle = resourceName end - _mapAuthor = getResourceInfo(resource, "author") + _mapAuthor = getResourceInfo(mapResource, "author") -- update game state setElementData(resourceRoot, "gameState", GAME_STARTING) -- inform all ready players that the game is about to start @@ -81,7 +81,7 @@ addEventHandler("onGamemodeMapStart", root, startGamemodeMap) -- -- stopGamemodeMap: cleans up a gamemode map -- -local function stopGamemodeMap(resource) +local function stopGamemodeMap(mapResource) -- end the round endRound(false, false, true) -- update game state