From aee8ed5a754b2b42851e9708ad811e9ff46f66c6 Mon Sep 17 00:00:00 2001 From: Oarcinae Date: Thu, 18 Oct 2018 14:47:19 -0400 Subject: [PATCH] Fixing bug when RSO is disabled. Thanks @xkuyax --- separate_spawns.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/separate_spawns.lua b/separate_spawns.lua index 1e0448b..a9c0cf8 100644 --- a/separate_spawns.lua +++ b/separate_spawns.lua @@ -316,7 +316,7 @@ function SendPlayerToNewSpawnAndCreateIt(playerName, spawn, moatEnabled) CreateWaterStrip(game.surfaces[GAME_SURFACE_NAME], {x=spawn.x+WATER_SPAWN_OFFSET_X, y=spawn.y+WATER_SPAWN_OFFSET_Y+1}, WATER_SPAWN_LENGTH) - GenerateStartingResources(surface, spawn) + GenerateStartingResources(game.surfaces[GAME_SURFACE_NAME], spawn) -- Send the player to that position game.players[playerName].teleport(spawn, GAME_SURFACE_NAME)