gitified + re-released my local modified version of abandoned mod.

This commit is contained in:
Someone
2020-05-02 22:36:22 +02:00
parent 46e6ed4534
commit ba1233872d
15 changed files with 1242 additions and 0 deletions

20
License.txt Normal file
View File

@@ -0,0 +1,20 @@
Copyright (c) 2017-2019 canidae
Copyright (c) 2020-2020 Someone <someone@somenet.org>
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

206
changelog.txt Normal file
View File

@@ -0,0 +1,206 @@
---------------------------------------------------------------------------------------------------
Version: 0.18.0
Date: 2020-05-02
Changed:
- Mod seemes abandoned. Fixed, git-ified and republished.
---------------------------------------------------------------------------------------------------
Version: 5.0.2
Date: 09. 04. 2019
Changes:
- Fixed setting research which broke with Factorio 0.17.26.
- Made the research strategy options look better.
---------------------------------------------------------------------------------------------------
Version: 5.0.1
Date: 03. 03. 2019
Changes:
- Keybinding (Shift-T) should work again.
- Filtering search results by ingredients should work properly again.
---------------------------------------------------------------------------------------------------
Version: 5.0.0
Date: 03. 03. 2019
Changes:
- Updated for Factorio 0.17.
- When AR is enabled, the in game research queue will be disabled.
---------------------------------------------------------------------------------------------------
Version: 4.3.1
Date: 03. 01. 2019
Changes:
- Complete russian translation, provided by user badway.
---------------------------------------------------------------------------------------------------
Version: 4.3.0
Date: 14. 10. 2018
Changes:
- Removed message about multiple technologies research within same tick, it served little purpose but spam.
---------------------------------------------------------------------------------------------------
Version: 4.2.0
Date: 05. 08. 2018
Changes:
- Players may choose a different research strategy. Research strategy will honor research queue & blacklist. Suggested by Foreros.
- Added mod setting for specifying default queue/blacklist (advanced usage). Suggested by oLaudix.
- Better support for research ingredients with multiple icons. Reported by GitHub user LovelySanta.
---------------------------------------------------------------------------------------------------
Version: 4.1.0
Date: 03. 04. 2018
Changes:
- Added possibility to filter search results by toggled ingredients. Feature provided by GitHub user sparr.
- Display all search results instead of just 30. Feature provided by GitHub user sparr.
- Improved search functionality, but still no localized search (game restriction). Feature provided by GitHub user sparr.
---------------------------------------------------------------------------------------------------
Version: 4.0.3
Date: 10. 02. 2018
Changes:
- When another mod (such as Timed Technology) changed research ingredients or energy to 0, AR effort calculation would result in all techs being considered having the same effort (0). This is no longer the case.
---------------------------------------------------------------------------------------------------
Version: 4.0.2
Date: 15. 12. 2017
Changes:
- Fixed issue with checkboxes not saving state.
---------------------------------------------------------------------------------------------------
Version: 4.0.1
Date: 15. 12. 2017
Changes:
- Fixed issue with remote interfaces, which is used by other mods to modify Auto Research settings.
---------------------------------------------------------------------------------------------------
Version: 4.0.0
Date: 14. 12. 2017
Changes:
- Updated for Factorio 0.16.
---------------------------------------------------------------------------------------------------
Version: 3.5.0
Date: 03. 07. 2017
Changes:
- Added buttons for moving queued tech to the top/bottom of the queue. Suggested by pokemonspeler.
- Right-clicking the search field removes the text. Suggested by Netoen.
---------------------------------------------------------------------------------------------------
Version: 3.4.0
Date: 13. 06. 2017
Changes:
- New setting: Deprioritize infinite tech. Disabled by default. When enabled AR will research all techs which are finite before researching infinite techs. Note that only technologies marked with the infinity symbol (∞) are considered infinite, technologies such as "Mining productivity 1-3" is considered a finite tech. Suggested by Solarwuff.
- When enabling all techs or for some other reason complete multiple technologies during the same tick, only the first technology will be announced. This is to prevent the chat from being spammed. Suggested by Sworn.
---------------------------------------------------------------------------------------------------
Version: 3.3.1
Date: 07. 05. 2017
Changes:
- Fixed issue where AR researched the least effort tech in queue rather than the highest prioritized tech.
---------------------------------------------------------------------------------------------------
Version: 3.3.0
Date: 07. 05. 2017
Changes:
- "Prioritized" has changed name to "Queued".
- "Deprioritized" is now "Blacklisted". Technologies added to this list will never be researched, even if there are no other technologies left to be researched. The old "Deprioritized" would research a technology if there were no other options, but this was a behavior that made more sense in earlier versions of the mod.
---------------------------------------------------------------------------------------------------
Version: 3.2.2
Date: 04. 05. 2017
Changes:
- Adding/removing/updating mods should no longer cause AR to reset allowed ingredients toggles.
---------------------------------------------------------------------------------------------------
Version: 3.2.1
Date: 04. 05. 2017
Changes:
- Adding a mod that introduced more research ingredients to an existing game with AR caused AR not to discover the new ingredients. This is now fixed.
---------------------------------------------------------------------------------------------------
Version: 3.2.0
Date: 03. 05. 2017
Changes:
- The setting "Fewest ingredients first" has been removed. It didn't work well with infinite research as certain infinite techs require 6 types of science packs while others require 7, meaning that the latter will never be researched as long as this setting was enabled. While the setting had its merits, it was a confusing option and the new ingredient filter works as a decent replacement.
- Added new setting "Only research prioritized" (default disabled). When this setting is checked AR will only start researching techs leading up to and including the prioritized techs. No prioritized techs; No automatic research of "least effort" techs.
- Prerequisites to prioritized techs weren't researched in a defined order. Now the least effort prerequisites will be researched first.
---------------------------------------------------------------------------------------------------
Version: 3.1.0
Date: 27. 04. 2017
Changes:
- The setting "Allow non-standard ingredients" has been replaced by an ingredient filter. You can now tell Auto Research to avoid technologies that requires ingredients you've filtered out in the GUI. Improvement suggested by Rhamphoryncus.
- Improved effort calculation by also including ingredient count. Improvement suggested by Optera.
- Ingredients added by other mods should in most cases now be displayed with the correct icon in the GUI rather than a question mark.
---------------------------------------------------------------------------------------------------
Version: 3.0.2
Date: 26. 04. 2017
Changes:
- I discovered that infinite research (such as "Mining Productivity") is displayed incorrectly in the game if a mod starts the next level of a research immediately upon completion of the previous level. If you queue up "Mining Productivity" then AR will first research "Mining Productivity 1", then "Mining Productivity 2", but in Factorio 0.15.2 it looks like it's researching "Mining Productivity 1" twice! Thus I removed the work-around in AR 3.0.1 as it's not AR doing anything wrong.
- Added technology level when broadcasting research completion.
---------------------------------------------------------------------------------------------------
Version: 3.0.1
Date: 26. 04. 2017
Changes:
- Fixed issue where wrong prerequisite technology was researched when prioritizing techs.
- Temporary work-around to prevent AR from researching the same level of certain technologies (such as "Mining Productivity").
---------------------------------------------------------------------------------------------------
Version: 3.0.0
Date: 24. 04. 2017
Changes:
- Only updated to work with Factorio 0.15.
---------------------------------------------------------------------------------------------------
Version: 2.2.1
Date: 05. 11. 2016
Changes:
- Fixed issue where AR would crash if you prioritized/deprioritized techs added by another mod, then removed the mod adding the tech.
---------------------------------------------------------------------------------------------------
Version: 2.2.0
Date: 23. 10. 2016
Changes:
- Added option to print technology name in console when research is finished.
- Auto Research will no longer cause game to freeze for a short time when you enable all technologies (commonly done in sandbox mode).
- Searching for technologies is now case insensitive.
---------------------------------------------------------------------------------------------------
Version: 2.1.0
Date: 06. 10. 2016
Changes:
- Deprioritized technologies will now only be researched when there's no other non-deprioritized technology available. Previously AR would research deprioritized technologies when "fewest first" was enabled and the deprioritized technologies was the last techs left with the fewest types of ingredients.
- Added ingredient icons to technology lists in GUI. Will (probably) show question mark for non-standard ingredients to technologies added by other mods.
- Cleaned up code. Probably broke shortcut key for those who've changed it from the default.
---------------------------------------------------------------------------------------------------
Version: 2.0.0
Date: 22. 09. 2016
Changes:
- Research Center is gone, replaced with a GUI. Sadly this means that you can't add a signal (such as the locomotive) to prioritize research. You can however search for technologies and items in the GUI, although you have to search for the prototype name and not the localized name (restriction imposed by game). Prototype name tend to be the same or nearly the same as the English localization.
- Technologies were not researched in the intended order, they should now.
- Added possibility to switch research even though previous research is not completed (as the game now saves your progress if you change research).
- Mod is enabled by default again.
- Keybinding for enabling/disabling Auto Research, non-standard research recipes and researching all technologies requiring fewest types of science packs first have been removed. These settings can be changed in the GUI.
---------------------------------------------------------------------------------------------------
Version: 1.0.1
Date: 18. 09. 2016
Changes:
- Sorting technology signals alphabetically.
---------------------------------------------------------------------------------------------------
Version: 1.0.0
Date: 16. 09. 2016
Changes:
- Added a "Research Center" for configuring AR from within the game.
- Removed config.lua as (most of) it can now be configured within the game using the Research Center.
- Proper support for multiple forces, each force have their own settings for AR.
- Added keybinding (Control+T) for enabling/disabling whether AR should research all technologies requiring fewest ingredients before moving on to technologies requiring more types of ingredients. Keybinding for enabling/disabling research of technologies requiring other ingredients than Science packs and Alien science pack has been moved to Alt+T. This may cause duplicate keybindings for those who upgrade AR from a previous version, solution is to manually set the keybindings.
---------------------------------------------------------------------------------------------------
Version: 0.7.0
Date: 12. 09. 2016
Changes:
- Update to make mod work with Factorio 0.14.
---------------------------------------------------------------------------------------------------
Version: 0.6.0
Date: 21. 08. 2016
Changes:
- Added keybinding (Control+T) for enabling/disabling research of technologies requiring other ingredients than Science packs and Alien science pack.
- Added config setting for avoiding certain technologies.
---------------------------------------------------------------------------------------------------
Version: 0.5.0
Date: 14. 08. 2016
Changes:
- Showing Research Queue popup when AR is disabled, hide it when AR is enabled.
---------------------------------------------------------------------------------------------------
Version: 0.4.0
Date: 12. 08. 2016
Changes:
- Added keybinding (Shift+T) for toggling AR on/off.
---------------------------------------------------------------------------------------------------
Version: 0.3.0
Date: 08. 08. 2016
Changes:
- Fixed an issue where Research Queue popup upon completing a research wasn't disabled.
---------------------------------------------------------------------------------------------------
Version: 0.2.0
Date: 07. 08. 2016
Changes:
- Added remote interface for enabling/disabling AR.
- Will research prerequisites to a prioritized technology.

734
control.lua Normal file
View File

@@ -0,0 +1,734 @@
function getConfig(force, config_changed)
if not global.auto_research_config then
global.auto_research_config = {}
-- Disable Research Queue popup
if remote.interfaces.RQ and remote.interfaces.RQ["popup"] then
remote.call("RQ", "popup", false)
end
end
if not global.auto_research_config[force.name] then
global.auto_research_config[force.name] = {
prioritized_techs = {}, -- "prioritized" is "queued". kept for backwards compatability (because i'm lazy and don't want migration code)
deprioritized_techs = {} -- "deprioritized" is "blacklisted". kept for backwards compatability (because i'm lazy and don't want migration code)
}
-- Enable Auto Research
setAutoResearch(force, true)
-- Disable queued only
setQueuedOnly(force, false)
-- Allow switching research
setAllowSwitching(force, true)
-- Print researched technology
setAnnounceCompletedResearch(force, true)
end
-- set research strategy
global.auto_research_config[force.name].research_strategy = global.auto_research_config[force.name].research_strategy or "balanced"
if config_changed or not global.auto_research_config[force.name].allowed_ingredients or not global.auto_research_config[force.name].infinite_research then
-- remember any old ingredients
local old_ingredients = {}
if global.auto_research_config[force.name].allowed_ingredients then
for name, enabled in pairs(global.auto_research_config[force.name].allowed_ingredients) do
old_ingredients[name] = enabled
end
end
-- find all possible tech ingredients
-- also scan for research that are infinite: techs that have no successor and tech.research_unit_count_formula is not nil
global.auto_research_config[force.name].allowed_ingredients = {}
global.auto_research_config[force.name].infinite_research = {}
local finite_research = {}
for _, tech in pairs(force.technologies) do
for _, ingredient in pairs(tech.research_unit_ingredients) do
global.auto_research_config[force.name].allowed_ingredients[ingredient.name] = (old_ingredients[ingredient.name] == nil or old_ingredients[ingredient.name])
end
if tech.research_unit_count_formula then
global.auto_research_config[force.name].infinite_research[tech.name] = tech
end
for _, pretech in pairs(tech.prerequisites) do
if pretech.enabled and not pretech.researched then
finite_research[pretech.name] = true
end
end
end
for techname, _ in pairs(finite_research) do
global.auto_research_config[force.name].infinite_research[techname] = nil
end
end
return global.auto_research_config[force.name]
end
function setAutoResearch(force, enabled)
if not force then
return
end
local config = getConfig(force)
config.enabled = enabled
force.research_queue_enabled = not enabled
if enabled then
-- start new research
startNextResearch(force)
end
end
function setQueuedOnly(force, enabled)
if not force then
return
end
getConfig(force).prioritized_only = enabled
-- start new research
startNextResearch(force)
end
function setAllowSwitching(force, enabled)
if not force then
return
end
getConfig(force).allow_switching = enabled
-- start new research
startNextResearch(force)
end
function setAnnounceCompletedResearch(force, enabled)
if not force then
return
end
getConfig(force).announce_completed = enabled
end
function setDeprioritizeInfiniteTech(force, enabled)
if not force then
return
end
getConfig(force).deprioritize_infinite_tech = enabled
-- start new research
startNextResearch(force)
end
function getPretechs(tech)
local pretechs = {}
pretechs[#pretechs + 1] = tech
local index = 1
while (index <= #pretechs) do
for _, pretech in pairs(pretechs[index].prerequisites) do
if pretech.enabled and not pretech.researched then
pretechs[#pretechs + 1] = pretech
end
end
index = index + 1
end
return pretechs
end
function canResearch(force, tech, config)
if not tech or tech.researched or not tech.enabled then
return false
end
for _, pretech in pairs(tech.prerequisites) do
if not pretech.researched then
return false
end
end
for _, ingredient in pairs(tech.research_unit_ingredients) do
if not config.allowed_ingredients[ingredient.name] then
return false
end
end
for _, deprioritized in pairs(config.deprioritized_techs) do
if tech.name == deprioritized then
return false
end
end
return true
end
function startNextResearch(force, override_spam_detection)
local config = getConfig(force)
if not config.enabled or (force.current_research and not config.allow_switching) or (not override_spam_detection and config.last_research_finish_tick == game.tick) then
return
end
config.last_research_finish_tick = game.tick -- if multiple research finish same tick for same force, the user probably enabled all techs
-- function for calculating tech effort
local calcEffort = function(tech)
local ingredientCount = function(ingredients)
local tech_ingredients = 0
for _, ingredient in pairs(tech.research_unit_ingredients) do
tech_ingredients = tech_ingredients + ingredient.amount
end
return tech_ingredients
end
local effort = 0
if config.research_strategy == "fast" then
effort = math.max(tech.research_unit_energy, 1) * math.max(tech.research_unit_count, 1)
elseif config.research_strategy == "slow" then
effort = math.max(tech.research_unit_energy, 1) * math.max(tech.research_unit_count, 1) * -1
elseif config.research_strategy == "cheap" then
effort = math.max(ingredientCount(tech.research_unit_ingredients), 1) * math.max(tech.research_unit_count, 1)
elseif config.research_strategy == "expensive" then
effort = math.max(ingredientCount(tech.research_unit_ingredients), 1) * math.max(tech.research_unit_count, 1) * -1
elseif config.research_strategy == "balanced" then
effort = math.max(tech.research_unit_count, 1) * math.max(tech.research_unit_energy, 1) * math.max(ingredientCount(tech.research_unit_ingredients), 1)
else
effort = math.random(1, 999)
end
if (config.deprioritize_infinite_tech and config.infinite_research[tech.name]) then
return effort * (effort > 0 and 1000 or -1000)
else
return effort
end
end
-- see if there are some techs we should research first
local next_research = nil
local least_effort = nil
for _, techname in pairs(config.prioritized_techs) do
local tech = force.technologies[techname]
if tech and not next_research then
local pretechs = getPretechs(tech)
for _, pretech in pairs(pretechs) do
local effort = calcEffort(pretech)
if (not least_effort or effort < least_effort) and canResearch(force, pretech, config) then
next_research = pretech.name
least_effort = effort
end
end
end
end
-- if no queued tech should be researched then research the "least effort" tech not researched yet
if not config.prioritized_only and not next_research then
for techname, tech in pairs(force.technologies) do
if tech.enabled and not tech.researched then
local effort = calcEffort(tech)
if (not least_effort or effort < least_effort) and canResearch(force, tech, config) then
next_research = techname
least_effort = effort
end
end
end
end
if next_research then
force.add_research(next_research)
end
end
function onResearchFinished(event)
local force = event.research.force
local config = getConfig(force)
-- remove researched stuff from prioritized_techs and deprioritized_techs
for i = #config.prioritized_techs, 1, -1 do
local tech = force.technologies[config.prioritized_techs[i]]
if not tech or tech.researched then
table.remove(config.prioritized_techs, i)
end
end
for i = #config.deprioritized_techs, 1, -1 do
local tech = force.technologies[config.deprioritized_techs[i]]
if not tech or tech.researched then
table.remove(config.deprioritized_techs, i)
end
end
-- announce completed research
if config.announce_completed and config.no_announce_this_tick ~= game.tick then
if config.last_research_finish_tick == game.tick then
config.no_announce_this_tick = game.tick
else
local level = ""
if event.research.research_unit_count_formula then
level = (event.research.researched and event.research.level) or (event.research.level - 1)
end
force.print{"auto_research.announce_completed", event.research.localised_name, level}
end
end
startNextResearch(event.research.force)
end
-- user interface
gui = {
toggleGui = function(player)
if player.gui.top.auto_research_gui then
player.gui.top.auto_research_gui.destroy()
else
local force = player.force
local config = getConfig(force)
local frame = player.gui.top.add{
type = "frame",
name = "auto_research_gui",
direction = "vertical",
caption = {"auto_research_gui.title"}
}
local frameflow = frame.add{
type = "flow",
style = "auto_research_list_flow",
name = "flow",
direction = "vertical"
}
-- checkboxes
frameflow.add{type = "checkbox", name = "auto_research_enabled", caption = {"auto_research_gui.enabled"}, tooltip = {"auto_research_gui.enabled_tooltip"}, state = config.enabled or false}
frameflow.add{type = "checkbox", name = "auto_research_queued_only", caption = {"auto_research_gui.prioritized_only"}, tooltip = {"auto_research_gui.prioritized_only_tooltip"}, state = config.prioritized_only or false}
frameflow.add{type = "checkbox", name = "auto_research_allow_switching", caption = {"auto_research_gui.allow_switching"}, tooltip = {"auto_research_gui.allow_switching_tooltip"}, state = config.allow_switching or false}
frameflow.add{type = "checkbox", name = "auto_research_announce_completed", caption = {"auto_research_gui.announce_completed"}, tooltip = {"auto_research_gui.announce_completed_tooltip"}, state = config.announce_completed or false}
frameflow.add{type = "checkbox", name = "auto_research_deprioritize_infinite_tech", caption = {"auto_research_gui.deprioritize_infinite_tech"}, tooltip = {"auto_research_gui.deprioritize_infinite_tech_tooltip"}, state = config.deprioritize_infinite_tech or false}
-- research strategy
frameflow.add{
type = "label",
style = "auto_research_header_label",
caption = {"auto_research_gui.research_strategy"}
}
local research_strategies_outer = frameflow.add{
type = "flow",
style = "auto_research_tech_flow",
name = "research_strategies_outer",
direction = "horizontal"
}
local research_strategies_left = research_strategies_outer.add{
type = "flow",
style = "auto_research_list_flow",
name = "research_strategies_left",
direction = "vertical"
}
research_strategies_left.add{type = "radiobutton", name = "auto_research_research_fast", caption = {"auto_research_gui.research_fast"}, tooltip = {"auto_research_gui.research_fast_tooltip"}, state = config.research_strategy == "fast"}
research_strategies_left.add{type = "radiobutton", name = "auto_research_research_cheap", caption = {"auto_research_gui.research_cheap"}, tooltip = {"auto_research_gui.research_cheap_tooltip"}, state = config.research_strategy == "cheap"}
research_strategies_left.add{type = "radiobutton", name = "auto_research_research_balanced", caption = {"auto_research_gui.research_balanced"}, tooltip = {"auto_research_gui.research_balanced_tooltip"}, state = config.research_strategy == "balanced"}
local research_strategies_right = research_strategies_outer.add{
type = "flow",
style = "auto_research_list_flow",
name = "research_strategies_right",
direction = "vertical"
}
research_strategies_right.style.left_padding = 15
research_strategies_right.add{type = "radiobutton", name = "auto_research_research_slow", caption = {"auto_research_gui.research_slow"}, tooltip = {"auto_research_gui.research_slow_tooltip"}, state = config.research_strategy == "slow"}
research_strategies_right.add{type = "radiobutton", name = "auto_research_research_expensive", caption = {"auto_research_gui.research_expensive"}, tooltip = {"auto_research_gui.research_expensive_tooltip"}, state = config.research_strategy == "expensive"}
research_strategies_right.add{type = "radiobutton", name = "auto_research_research_random", caption = {"auto_research_gui.research_random"}, tooltip = {"auto_research_gui.research_random_tooltip"}, state = config.research_strategy == "random"}
-- allowed ingredients
frameflow.add{
type = "label",
style = "auto_research_header_label",
caption = {"auto_research_gui.allowed_ingredients_label"}
}
local allowed_ingredients = frameflow.add{
type = "flow",
style = "auto_research_list_flow",
name = "allowed_ingredients",
direction = "vertical"
}
gui.updateAllowedIngredientsList(player.gui.top.auto_research_gui.flow.allowed_ingredients, player, config)
-- prioritized techs
frameflow.add{
type = "label",
style = "auto_research_header_label",
caption = {"auto_research_gui.prioritized_label"}
}
local prioritized = frameflow.add{
type = "scroll-pane",
name = "prioritized",
horizontal_scroll_policy = "never",
vertical_scroll_policy = "auto"
}
prioritized.style.top_padding = 5
prioritized.style.bottom_padding = 5
prioritized.style.maximal_height = 127
-- draw prioritized tech list
gui.updateTechnologyList(player.gui.top.auto_research_gui.flow.prioritized, config.prioritized_techs, player, true)
-- deprioritized techs
frameflow.add{
type = "label",
style = "auto_research_header_label",
caption = {"auto_research_gui.deprioritized_label"}
}
local deprioritized = frameflow.add{
type = "scroll-pane",
name = "deprioritized",
horizontal_scroll_policy = "never",
vertical_scroll_policy = "auto"
}
deprioritized.style.top_padding = 5
deprioritized.style.bottom_padding = 5
deprioritized.style.maximal_height = 127
-- draw deprioritized tech list
gui.updateTechnologyList(player.gui.top.auto_research_gui.flow.deprioritized, config.deprioritized_techs, player)
-- search for techs
local searchflow = frameflow.add{
type = "flow",
name = "searchflow",
style = "auto_research_tech_flow",
direction = "horizontal"
}
searchflow.add{
type = "label",
style = "auto_research_header_label",
caption = {"auto_research_gui.search_label"}
}
searchflow.add{
type = "textfield",
name = "auto_research_search_text",
tooltip = {"auto_research_gui.search_tooltip"}
}
local searchoptionsflow = frameflow.add{
type = "flow",
name = "searchoptionsflow",
style = "auto_research_tech_flow",
direction = "horizontal"
}
searchoptionsflow.add{
type = "checkbox",
name = "auto_research_ingredients_filter_search_results",
caption = {"auto_research_gui.ingredients_filter_search_results"},
tooltip = {"auto_research_gui.ingredients_filter_search_results_tooltip"},
state = config.filter_search_results or false
}
local search = frameflow.add{
type = "scroll-pane",
name = "search",
horizontal_scroll_policy = "never",
vertical_scroll_policy = "auto"
}
search.style.top_padding = 5
search.style.bottom_padding = 5
search.style.maximal_height = 127
-- draw search result list
gui.updateSearchResult(player, "")
end
end,
onCheckboxClick = function(event)
local player = game.players[event.player_index]
local force = player.force
local name = event.element.name
if name == "auto_research_enabled" then
setAutoResearch(force, event.element.state)
elseif name == "auto_research_queued_only" then
setQueuedOnly(force, event.element.state)
elseif name == "auto_research_allow_switching" then
setAllowSwitching(force, event.element.state)
elseif name == "auto_research_announce_completed" then
setAnnounceCompletedResearch(force, event.element.state)
elseif name == "auto_research_deprioritize_infinite_tech" then
setDeprioritizeInfiniteTech(force, event.element.state)
elseif name == "auto_research_ingredients_filter_search_results" then
local config = getConfig(force)
config.filter_search_results = event.element.state
gui.updateSearchResult(player, player.gui.top.auto_research_gui.flow.searchflow.auto_research_search_text.text)
end
end,
onClick = function(event)
local player = game.players[event.player_index]
local force = player.force
local config = getConfig(force)
local name = event.element.name
if name == "auto_research_search_text" then
if event.button == defines.mouse_button_type.right then
player.gui.top.auto_research_gui.flow.searchflow.auto_research_search_text.text = ""
gui.updateSearchResult(player, player.gui.top.auto_research_gui.flow.searchflow.auto_research_search_text.text)
end
elseif string.find(name, "auto_research_research") then
config.research_strategy = string.match(name, "^auto_research_research_(.*)$")
player.gui.top.auto_research_gui.flow.research_strategies_outer.research_strategies_left.auto_research_research_fast.state = (config.research_strategy == "fast")
player.gui.top.auto_research_gui.flow.research_strategies_outer.research_strategies_left.auto_research_research_cheap.state = (config.research_strategy == "cheap")
player.gui.top.auto_research_gui.flow.research_strategies_outer.research_strategies_left.auto_research_research_balanced.state = (config.research_strategy == "balanced")
player.gui.top.auto_research_gui.flow.research_strategies_outer.research_strategies_right.auto_research_research_slow.state = (config.research_strategy == "slow")
player.gui.top.auto_research_gui.flow.research_strategies_outer.research_strategies_right.auto_research_research_expensive.state = (config.research_strategy == "expensive")
player.gui.top.auto_research_gui.flow.research_strategies_outer.research_strategies_right.auto_research_research_random.state = (config.research_strategy == "random")
-- start new research
startNextResearch(force)
else
local prefix, name = string.match(name, "^auto_research_([^-]*)-(.*)$")
if prefix == "allow_ingredient" then
config.allowed_ingredients[name] = not config.allowed_ingredients[name]
gui.updateAllowedIngredientsList(player.gui.top.auto_research_gui.flow.allowed_ingredients, player, config)
if player.gui.top.auto_research_gui.flow.searchoptionsflow.auto_research_ingredients_filter_search_results.state then
gui.updateSearchResult(player, player.gui.top.auto_research_gui.flow.searchflow.auto_research_search_text.text)
end
startNextResearch(force)
elseif name and force.technologies[name] then
-- remove tech from prioritized list
for i = #config.prioritized_techs, 1, -1 do
if config.prioritized_techs[i] == name then
table.remove(config.prioritized_techs, i)
end
end
-- and from deprioritized list
for i = #config.deprioritized_techs, 1, -1 do
if config.deprioritized_techs[i] == name then
table.remove(config.deprioritized_techs, i)
end
end
if prefix == "queue_top" then
-- add tech to top of prioritized list
table.insert(config.prioritized_techs, 1, name)
elseif prefix == "queue_bottom" then
-- add tech to bottom of prioritized list
table.insert(config.prioritized_techs, name)
elseif prefix == "blacklist" then
-- add tech to list of deprioritized techs
table.insert(config.deprioritized_techs, name)
end
gui.updateTechnologyList(player.gui.top.auto_research_gui.flow.prioritized, config.prioritized_techs, player, true)
gui.updateTechnologyList(player.gui.top.auto_research_gui.flow.deprioritized, config.deprioritized_techs, player)
gui.updateSearchResult(player, player.gui.top.auto_research_gui.flow.searchflow.auto_research_search_text.text)
-- start new research
startNextResearch(force)
end
end
end,
updateAllowedIngredientsList = function(flow, player, config)
local counter = 1
while flow["flow" .. counter] do
flow["flow" .. counter].destroy()
counter = counter + 1
end
counter = 1
for ingredientname, allowed in pairs(config.allowed_ingredients) do
local flowname = "flow" .. math.floor(counter / 10) + 1
local ingredientflow = flow[flowname]
if not ingredientflow then
ingredientflow = flow.add {
type = "flow",
style = "auto_research_tech_flow",
name = flowname,
direction = "horizontal"
}
end
local sprite = "auto_research_tool_" .. ingredientname
if not player.gui.is_valid_sprite_path(sprite) then
sprite = "auto_research_unknown"
end
ingredientflow.add{type = "sprite-button", style = "auto_research_sprite_button_toggle" .. (allowed and "_pressed" or ""), name = "auto_research_allow_ingredient-" .. ingredientname, tooltip = {"item-name." .. ingredientname}, sprite = sprite}
counter = counter + 1
end
end,
updateTechnologyList = function(scrollpane, technologies, player, show_queue_buttons)
if scrollpane.flow then
scrollpane.flow.destroy()
end
local flow = scrollpane.add{
type = "flow",
style = "auto_research_list_flow",
name = "flow",
direction = "vertical"
}
if #technologies > 0 then
for _, techname in pairs(technologies) do
local tech = player.force.technologies[techname]
if tech then
local entryflow = flow.add{type = "flow", style = "auto_research_tech_flow", direction = "horizontal"}
if show_queue_buttons then
entryflow.add{type = "sprite-button", style = "auto_research_sprite_button", name = "auto_research_queue_top-" .. techname, sprite = "auto_research_prioritize_top"}
entryflow.add{type = "sprite-button", style = "auto_research_sprite_button", name = "auto_research_queue_bottom-" .. techname, sprite = "auto_research_prioritize_bottom"}
end
entryflow.add{type = "sprite-button", style = "auto_research_sprite_button", name = "auto_research_delete-" .. techname, sprite = "auto_research_delete"}
entryflow.add{type = "label", style = "auto_research_tech_label", caption = tech.localised_name}
for _, ingredient in pairs(tech.research_unit_ingredients) do
local sprite = "auto_research_tool_" .. ingredient.name
if not player.gui.is_valid_sprite_path(sprite) then
sprite = "auto_research_unknown"
end
entryflow.add{type = "sprite", style = "auto_research_sprite", sprite = sprite}
end
end
end
else
local entryflow = flow.add{type = "flow", direction = "horizontal"}
entryflow.add{type = "label", caption = {"auto_research_gui.none"}}
end
end,
updateSearchResult = function(player, text)
local scrollpane = player.gui.top.auto_research_gui.flow.search
if scrollpane.flow then
scrollpane.flow.destroy()
end
local flow = scrollpane.add{
type = "flow",
style = "auto_research_list_flow",
name = "flow",
direction = "vertical"
}
local ingredients_filter = player.gui.top.auto_research_gui.flow.searchoptionsflow.auto_research_ingredients_filter_search_results.state
local config = getConfig(player.force)
local shown = 0
text = string.lower(text)
-- NOTICE: localised name matching does not work at present, pending unlikely changes to Factorio API
for name, tech in pairs(player.force.technologies) do
if not tech.researched and tech.enabled then
local showtech = false
if string.find(string.lower(name), text, 1, true) then
-- show techs that match by name
showtech = true
-- elseif string.find(string.lower(game.technology_prototypes[name].localised_name), text, 1, true) then
-- -- show techs that match by localised name
-- showtech = true
else
for _, effect in pairs(tech.effects) do
if string.find(effect.type, text, 1, true) then
-- show techs that match by effect type
showtech = true
elseif effect.type == "unlock-recipe" then
if string.find(effect.recipe, text, 1, true) then
-- show techs that match by unlocked recipe name
showtech = true
-- elseif string.find(string.lower(game.recipe_prototypes[effect.recipe].localised_name), text, 1, true) then
-- -- show techs that match by unlocked recipe localised name
-- showtech = true
else
for _, product in pairs(game.recipe_prototypes[effect.recipe].products) do
if string.find(product.name, text, 1, true) then
-- show techs that match by unlocked recipe product name
showtech = true
-- elseif string.find(string.lower(game.item_prototypes[product.name].localised_name), text, 1, true) then
-- -- show techs that match by unlocked recipe product localised name
-- showtech = true
else
local prototype = game.item_prototypes[product.name]
if prototype then
if prototype.place_result then
if string.find(prototype.place_result.name, text, 1, true) then
-- show techs that match by unlocked recipe product placed entity name
showtech = true
-- elseif string.find(string.lower(game.entity_prototypes[prototype.place_result.name].localised_name), text, 1, true) then
-- -- show techs that match by unlocked recipe product placed entity localised name
-- showtech = true
end
elseif prototype.place_as_equipment_result then
if string.find(prototype.place_as_equipment_result.name, text, 1, true) then
-- show techs that match by unlocked recipe product placed equipment name
showtech = true
-- elseif string.find(string.lower(game.equipment_prototypes[prototype.place_as_equipment_result.name].localised_name), text, 1, true) then
-- -- show techs that match by unlocked recipe product placed equipment localised name
-- showtech = true
end
elseif prototype.place_as_tile_result then
if string.find(prototype.place_as_tile_result.result.name, text, 1, true) then
-- show techs that match by unlocked recipe product placed tile name
showtech = true
-- elseif string.find(string.lower(prototype.place_as_tile_result.result.localised_name), text, 1, true) then
-- -- show techs that match by unlocked recipe product placed tile localised name
-- showtech = true
end
end
end
end
end
end
end
end
end
if showtech and config.prioritized_techs then
for _, queued_tech in pairs(config.prioritized_techs) do
if name == queued_tech then
showtech = false
break
end
end
end
if showtech and config.deprioritized_techs then
for _, blacklisted_tech in pairs(config.deprioritized_techs) do
if name == blacklisted_tech then
showtech = false
break
end
end
end
if showtech and ingredients_filter then
for _, ingredient in pairs(tech.research_unit_ingredients) do
if not config.allowed_ingredients[ingredient.name] then
-- filter out techs that require disallowed ingredients (optional)
showtech = false
end
end
end
if showtech then
shown = shown + 1
local entryflow = flow.add{type = "flow", style = "auto_research_tech_flow", direction = "horizontal"}
entryflow.add{type = "sprite-button", style = "auto_research_sprite_button", name = "auto_research_queue_top-" .. name, sprite = "auto_research_prioritize_top"}
entryflow.add{type = "sprite-button", style = "auto_research_sprite_button", name = "auto_research_queue_bottom-" .. name, sprite = "auto_research_prioritize_bottom"}
entryflow.add{type = "sprite-button", style = "auto_research_sprite_button", name = "auto_research_blacklist-" .. name, sprite = "auto_research_deprioritize"}
entryflow.add{type = "label", style = "auto_research_tech_label", name = name, caption = tech.localised_name}
for _, ingredient in pairs(tech.research_unit_ingredients) do
local sprite = "auto_research_tool_" .. ingredient.name
if not player.gui.is_valid_sprite_path(sprite) then
sprite = "auto_research_unknown"
end
entryflow.add{type = "sprite", style = "auto_research_sprite", sprite = sprite}
end
end
end
end
end
}
-- event hooks
script.on_configuration_changed(function()
for _, force in pairs(game.forces) do
getConfig(force, true) -- triggers initialization of force config
end
end)
script.on_event(defines.events.on_player_created, function(event)
local force = game.players[event.player_index].force
local config = getConfig(force) -- triggers initialization of force config
-- set any default queued/blacklisted techs
local queued_tech = settings.get_player_settings(game.players[event.player_index])["queued-tech-setting"].value
for tech in string.gmatch(queued_tech, "[^,$]+") do
tech = string.gsub(tech, "%s+", "")
if force.technologies[tech] and force.technologies[tech].enabled and not force.technologies[tech].researched then
table.insert(config.prioritized_techs, tech)
end
end
local blacklisted_tech = settings.get_player_settings(game.players[event.player_index])["blacklisted-tech-setting"].value
for tech in string.gmatch(blacklisted_tech, "[^,$]+") do
tech = string.gsub(tech, "%s+", "")
if force.technologies[tech] and force.technologies[tech].enabled and not force.technologies[tech].researched then
table.insert(config.deprioritized_techs, tech)
end
end
startNextResearch(force, true)
end)
script.on_event(defines.events.on_force_created, function(event)
getConfig(event.force) -- triggers initialization of force config
end)
script.on_event(defines.events.on_research_finished, onResearchFinished)
script.on_event(defines.events.on_gui_checked_state_changed, gui.onCheckboxClick)
script.on_event(defines.events.on_gui_click, gui.onClick)
script.on_event(defines.events.on_gui_text_changed, function(event)
if event.element.name ~= "auto_research_search_text" then
return
end
gui.updateSearchResult(game.players[event.player_index], event.element.text)
end)
-- keybinding hooks
script.on_event("auto_research_toggle", function(event)
local player = game.players[event.player_index]
gui.toggleGui(player)
end)
-- Add remote interfaces for enabling/disabling Auto Research
remote.add_interface("auto_research", {
enabled = function(forcename, value) setAutoResearch(game.forces[forcename], value) end,
queued_only = function(forcename, value) setQueuedOnly(game.forces[forcename], value) end,
allow_switching = function(forcename, value) setAllowSwitching(game.forces[forcename], value) end,
announce_completed = function(forcename, value) setAnnounceCompletedResearch(game.forces[forcename], value) end,
deprioritize_infinite_tech = function(forcename, value) setDeprioritizeInfiniteTech(game.forces[forcename], value) end
})

15
data-final-fixes.lua Normal file
View File

@@ -0,0 +1,15 @@
-- dynamically add sprites for tools (to display research ingredients)
for _, tool in pairs(data.raw.tool) do
if tool.icon or tool.icons then
data:extend({
{
type = "sprite",
name = "auto_research_tool_" .. tool.name,
filename = tool.icon or (tool.icons[1] and tool.icons[1].icon) or nil,
priority = "extra-high-no-scale",
width = 64,
height = 64
}
})
end
end

145
data.lua Normal file
View File

@@ -0,0 +1,145 @@
data.raw["gui-style"].default["auto_research_header_label"] = {
type = "label_style",
font_color = {r = .91764705882352941176, g = .85098039215686274509, b = .67450980392156862745},
font = "default-large-semibold",
top_padding = 0,
bottom_padding = 0,
left_padding = 0,
right_padding = 6
}
data.raw["gui-style"].default["auto_research_list_flow"] = {
type = "vertical_flow_style",
vertical_spacing = 0
}
data.raw["gui-style"].default["auto_research_tech_flow"] = {
type = "horizontal_flow_style",
horizontal_spacing = 0,
resize_row_to_width = true
}
data.raw["gui-style"].default["auto_research_sprite_button"] = {
type = "button_style",
width = 24,
height = 24,
top_padding = 0,
right_padding = 0,
bottom_padding = 0,
left_padding = 0,
left_click_sound = {
{
filename = "__core__/sound/gui-click.ogg",
volume = 1
}
}
}
data.raw["gui-style"].default["auto_research_sprite_button_toggle"] = {
type = "button_style",
parent = "auto_research_sprite_button",
default_graphical_set = {
type = "composition",
filename = "__core__/graphics/gui.png",
priority = "extra-high-no-scale",
load_in_minimal_mode = true,
corner_size = {3, 3},
position = {0, 0}
},
hovered_graphical_set = {
type = "composition",
filename = "__core__/graphics/gui.png",
priority = "extra-high-no-scale",
load_in_minimal_mode = true,
corner_size = {3, 3},
position = {0, 8}
}
}
data.raw["gui-style"].default["auto_research_sprite_button_toggle_pressed"] = {
type = "button_style",
parent = "auto_research_sprite_button_toggle",
default_graphical_set = {
type = "composition",
filename = "__core__/graphics/gui.png",
priority = "extra-high-no-scale",
load_in_minimal_mode = true,
corner_size = {3, 3},
position = {0, 40}
},
hovered_graphical_set = {
type = "composition",
filename = "__core__/graphics/gui.png",
priority = "extra-high-no-scale",
load_in_minimal_mode = true,
corner_size = {3, 3},
position = {0, 48}
}
}
data.raw["gui-style"].default["auto_research_tech_label"] = {
type = "label_style",
left_padding = 4,
right_padding = 4
}
data.raw["gui-style"].default["auto_research_sprite"] = {
type = "image_style",
width = 24,
height = 24,
top_padding = 0,
right_padding = 0,
bottom_padding = 0,
left_padding = 0
}
data:extend({
-- keybindings
{
type = "custom-input",
name = "auto_research_toggle",
key_sequence = "SHIFT + T"
},
-- sprites
{
type = "sprite",
name = "auto_research_prioritize_top",
filename = "__some-autoresearch__/graphics/prioritize_top.png",
priority = "extra-high-no-scale",
width = 32,
height = 32
},
{
type = "sprite",
name = "auto_research_prioritize_bottom",
filename = "__some-autoresearch__/graphics/prioritize_bottom.png",
priority = "extra-high-no-scale",
width = 32,
height = 32
},
{
type = "sprite",
name = "auto_research_deprioritize",
filename = "__some-autoresearch__/graphics/deprioritize.png",
priority = "extra-high-no-scale",
width = 32,
height = 32
},
{
type = "sprite",
name = "auto_research_delete",
filename = "__some-autoresearch__/graphics/delete.png",
priority = "extra-high-no-scale",
width = 32,
height = 32
},
{
type = "sprite",
name = "auto_research_unknown",
filename = "__some-autoresearch__/graphics/questionmark.png",
priority = "extra-high-no-scale",
width = 32,
height = 32
}
})

BIN
graphics/delete.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

BIN
graphics/deprioritize.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 574 B

BIN
graphics/prioritize_top.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 571 B

BIN
graphics/questionmark.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 419 B

10
info.json Normal file
View File

@@ -0,0 +1,10 @@
{
"name": "auto-research (fixed + re-published)",
"version": "0.18.0",
"title": "Auto Research (fixed + re-published)",
"author": "Someone (originally canidae)",
"homepage": "https://git.somenet.org/pub/jan/factorio_some-autoresearch.git",
"description": "Automates research. Toggle GUI with Shift+T (customizable).",
"dependencies": ["base"],
"factorio_version": "0.18"
}

47
locale/en/en.cfg Normal file
View File

@@ -0,0 +1,47 @@
[auto_research]
announce_completed=[Auto Research] Research completed: __1__ __2__
[auto_research_gui]
title=Auto Research
enabled=Enable Auto Research
enabled_tooltip=Automatically start new research
prioritized_only=Only research queued
prioritized_only_tooltip=Only research queued techs and their prerequisites. No queue, no automatic research
allow_switching=Allow switching research
allow_switching_tooltip=Let Auto Research change the current research when you change research queue/settings
announce_completed=Announce completed research
announce_completed_tooltip=Print the name of the technology when research is completed
deprioritize_infinite_tech=Deprioritize infinite tech
deprioritize_infinite_tech_tooltip=Do not research infinite techs before all finite techs have been researched
allowed_ingredients_label=Allowed research ingredients:
prioritized_label=Queued research:
deprioritized_label=Blacklisted research:
none=<none>
search_label=Search:
search_tooltip=Search for technology or item to queue/blacklist research
ingredients_filter_search_results=Ingredients filter results
ingredients_filter_search_results_tooltip=Only show search results that match the allowed ingredient list above
research_strategy=Research strategy:
research_fast=Fast
research_fast_tooltip=Prioritize techs that take the least time to finish
research_slow=Slow
research_slow_tooltip=Prioritize techs that take the most time finish
research_cheap=Cheap
research_cheap_tooltip=Prioritize techs that require the least amount of ingredients
research_expensive=Expensive
research_expensive_tooltip=Prioritize techs that require the most amount of ingredients
research_balanced=Balanced
research_balanced_tooltip=Prioritize techs with a fast/cheap balance
research_random=Random
research_random_tooltip=Prioritize techs in a random order
[controls]
auto_research_toggle=Toggle Auto Research GUI
[mod-setting-name]
queued-tech-setting=Default queued techs
blacklisted-tech-setting=Default blacklisted techs
[mod-setting-description]
queued-tech-setting=List techs separated by commas, to automatically queue them in new games. You must use the tech id, such as "construction-robotics" and not the localized name.
blacklisted-tech-setting=List techs separated by commas, to automatically blacklist them in new games. You must use the tech id, such as "construction-robotics" and not the localized name.

47
locale/ru/ru.cfg Normal file
View File

@@ -0,0 +1,47 @@
[auto_research]
announce_completed=[Автоисследование] Исследование завершено: __1__ __2__
[auto_research_gui]
title=Автоисследование
enabled=Включить автоисследование
enabled_tooltip=Автоматически начинать новое исследование
prioritized_only=Исследовать только по очереди
prioritized_only_tooltip=Исследовать только техлоногии, добавленные в очередь, а так же их зависимости. Нет очереди - не исследований.
allow_switching=Разрешить переключение исследований
allow_switching_tooltip=Позволить Автоисследованию менять нынешнюю разработку, когда Вы меняеете очередь\настройки.
announce_completed=Анонсировать завершение разаработки
announce_completed_tooltip=Писать название технологии, когда её исследование завершено.
deprioritize_infinite_tech=Деприоритезировать бесконечные технологии
deprioritize_infinite_tech_tooltip=Не исследовать бесконечные технологии, пока не будут исследованы все конечные технологии.
allowed_ingredients_label=Разрешённые исследовательские пакеты:
prioritized_label=Очередь исследований:
deprioritized_label=Чёрный список исследований:
none=<пусто>
search_label=Поиск:
search_tooltip=Искать технологгию или предмет для добавления в очередь\чёрный список
ingredients_filter_search_results=Фильтровать по научным пакетам
ingredients_filter_search_results_tooltip=Показывать только результаты поиска, которые соответствуют списку разрешенных ингредиентов выше
research_strategy=Стратегия исследования:
research_fast=Быстро
research_fast_tooltip=Приоритет технологий, которые занимают меньше всего времени.
research_slow=Медлено
research_slow_tooltip=Приоритет технологий, которые занимают больше всего времени.
research_cheap=Дешево
research_cheap_tooltip=Приоритет технологий, которые требуют наименьшего количества ингредиентов
research_expensive=Дорого
research_expensive_tooltip=Приоритет технологий, которые требуют наибольшего количества ингредиентов
research_balanced=Сбалансировано
research_balanced_tooltip=Приоритет технологий с быстрым / дешевым балансом
research_random=Случайно
research_random_tooltip=В случайном порядке
[controls]
auto_research_toggle=Меню автоисследований
[mod-setting-name]
queued-tech-setting=Очередь технологий по умолчанию
blacklisted-tech-setting=Черный список по умолчанию
[mod-setting-description]
queued-tech-setting=Список технологий, разделенных запятыми, чтобы автоматически ставить их в очередь в новых играх. Вы должны использовать технический идентификатор, такой как «construction-robotics», а не локализованное имя.
blacklisted-tech-setting=Список технологий, разделенных запятыми, чтобы автоматически занести их в черный список в новых играх. Вы должны использовать технический идентификатор, такой как «construction-robotics», а не локализованное имя.

18
settings.lua Normal file
View File

@@ -0,0 +1,18 @@
data:extend({
{
type = "string-setting",
allow_blank = "true",
name = "queued-tech-setting",
setting_type = "runtime-per-user",
default_value = "",
order = "1"
},
{
type = "string-setting",
allow_blank = "true",
name = "blacklisted-tech-setting",
setting_type = "runtime-per-user",
default_value = "",
order = "2"
}
})

BIN
thumbnail.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB