Add joinable legacy code

This commit is contained in:
Cooldude2606 committed 2024-11-19 22:16:34 +00:00
1 parent 2a1206c498
commit d24555d805
24 files changed
+144 -126

No files matched your search

@@ -18,7 +18,7 @@ Event.add(defines.events.on_player_created, function(event)
-- spawn items
for item, callback in pairs(items) do
if type(callback) == 'function' then
local stats = player.force.item_production_statistics
local stats = player.force.get_item_production_statistics(player.surface)
local made = stats.get_input_count(item)
local success, count = pcall(callback, made, stats.get_input_count, player)
count = math.floor(count)