From b9f1ac970a076e7e1951b6fdd6c3327c3f53e603 Mon Sep 17 00:00:00 2001 From: Someone Date: Sun, 16 Aug 2020 04:48:49 +0200 Subject: [PATCH] instert things again. --- control.lua | 25 ++++++++++++++++--------- 1 file changed, 16 insertions(+), 9 deletions(-) diff --git a/control.lua b/control.lua index f53174b..8290e84 100755 --- a/control.lua +++ b/control.lua @@ -1,12 +1,19 @@ --- only needed on first startup. Create stuff and be done. -script.on_event(defines.events.on_player_created, function (event) - game.permissions.get_group("Default").set_allows_action(defines.input_action.craft ,false) +script.on_init(function (event) + game.permissions.get_group("Default").set_allows_action(defines.input_action.craft ,false) + + remote.call("freeplay", "set_created_items", { + ["iron-plate"] = 8, + ["wood"] = 1, + ["pistol"] = 1, + ["firearm-magazine"] = 10, + ["burner-mining-drill"] = 1, + ["stone-furnace"] = 1, + ["assembling-machine-3"] = 1, + ["small-electric-pole"] = 1, + ["boiler"] = 1, + ["steam-engine"] = 1, + ["offshore-pump"] = 1 + }) - local player = game.players[event.player_index] - player.insert{name="assembling-machine-3", count=1} - player.insert{name="small-electric-pole", count=1} - player.insert{name="boiler", count=1} - player.insert{name="steam-engine", count=1} - player.insert{name="offshore-pump", count=1} end) -- 2.43.0