Multiplayer desyncs
Posted: Wed Oct 26, 2016 1:20 pm
I found a way (crapy one) to implement the server-client logic to factorio using global table:
and you need to execute this code for all (new) players:
And you may also use another instance of global table to match player names with their indexes.
Code: Select all
global.player_index = 0
local get_player_index = function()
global.player_index = global.player_index + 1
return global.player_index
end
Code: Select all
local player_index = get_player_index()