From 4116dc4fe2e8f1385d1c37f19df2c8c776548f90 Mon Sep 17 00:00:00 2001 From: Brevven Date: Sun, 14 Aug 2022 19:55:37 -0700 Subject: [PATCH] start with burner inserter --- control.lua | 16 ++++++++++++++++ locale/en/aluminum.cfg | 2 ++ settings.lua | 6 ++++++ 3 files changed, 24 insertions(+) diff --git a/control.lua b/control.lua index 2afa613..838f9aa 100644 --- a/control.lua +++ b/control.lua @@ -14,3 +14,19 @@ function on_console_chat(event) end end script.on_event(defines.events.on_console_chat, on_console_chat) + + +-- Free burner inserter +-- (thanks to modder planetfall for inspiration, from Brass Tacks) +script.on_init( + function() + if remote.interfaces["freeplay"] then + local care_package = remote.call("freeplay", "get_created_items") + if settings.global["bzaluminum-starting-items"].value then + care_package["burner-inserter"] = 1 + end + remote.call("freeplay", "set_created_items", care_package) + end + end +) + diff --git a/locale/en/aluminum.cfg b/locale/en/aluminum.cfg index 79b0540..8cd0579 100644 --- a/locale/en/aluminum.cfg +++ b/locale/en/aluminum.cfg @@ -76,8 +76,10 @@ dirty-water-filtration-aluminum=Filter dirty water, giving __ITEM__aluminum_lowe bzaluminum-recipe-bypass=Bypass recipes bzaluminum-list=Make a list of modified recipes bzaluminum-byproduct=Output byproducts +bzaluminum-starting-items=Start with a burner inserter [mod-setting-description] bzaluminum-recipe-bypass=Skip modifying these recipes (comma-separated list). bzaluminum-list=If enabled, the text command [color=orange]BZList[/color] will dump a file to the script-output directory with a full list of recipes modified.\nRecommended to turn this off after you are done configuring your other settings. bzaluminum-byproduct=If enabled, and if silica is used, __ITEM__aluminum_lower__ production will output silica as a byproduct. +bzaluminum-starting-items=Burner inserters require aluminum to make, which means manually moving alumina around. Leave this setting on to get a single burner inserter to propel you forward by a few seconds in a new game. diff --git a/settings.lua b/settings.lua index 940cff4..2883ac3 100644 --- a/settings.lua +++ b/settings.lua @@ -18,4 +18,10 @@ data:extend({ setting_type = "startup", default_value = false, }, + { + type = "bool-setting", + name = "bzaluminum-starting-items", + setting_type = "runtime-global", + default_value = true, + }, })