mirror of
https://github.com/Oarcinae/FactorioScenarioMultiplayerSpawn.git
synced 2024-12-14 10:23:17 +02:00
Fixing crash when first player leaves too early.
Fixing crash when first player leaves too early.
This commit is contained in:
parent
262a1d99c3
commit
6f78237362
@ -83,7 +83,7 @@ function FindUnusedSpawns(event)
|
||||
end
|
||||
|
||||
-- Remove a force if this player created it and they are the only one on it
|
||||
if (#player.force.players <= 1) then
|
||||
if ((#player.force.players <= 1) and (player.force.name ~= MAIN_FORCE)) then
|
||||
game.merge_forces(player.force, MAIN_FORCE)
|
||||
end
|
||||
|
||||
@ -284,4 +284,4 @@ function ShareVisionBetweenPlayers()
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user