mirror of
https://github.com/peter-tanner/factorio-shortcuts.git
synced 2024-11-30 11:10:22 +08:00
V 0.2.1: attempt to fix data.lua item error
This commit is contained in:
parent
31b1ae088f
commit
a596f824ba
|
@ -23,16 +23,19 @@ for i=1,(#equipment_list) do
|
|||
local name = disabled_equipment[i].name
|
||||
local newname = "disabled-" .. name
|
||||
disabled_equipment[i].name = newname
|
||||
disabled_equipment[i].localised_name = {"", {"equipment-name." .. name}, " (", {"gui-constant.off"}, ")"}
|
||||
disabled_equipment[i].energy_input = "0kW"
|
||||
if equipment_list[i] == "belt-immunity-equipment" then
|
||||
disabled_equipment[i].energy_source.input_flow_limit = "0kW"
|
||||
disabled_equipment[i].energy_source.buffer_capacity = "0kJ"
|
||||
disabled_equipment[i].energy_source.drain = "1kW"
|
||||
end
|
||||
if not disabled_equipment_item[i] then
|
||||
disabled_equipment_item[i] = util.table.deepcopy(data.raw["item"]["night-vision-equipment"])
|
||||
end
|
||||
disabled_equipment_item[i].name = newname
|
||||
disabled_equipment_item[i].localised_name = {"", {"equipment-name." .. name}, " (", {"gui-constant.off"}, ")"}
|
||||
disabled_equipment_item[i].localised_description = {"item-description." .. name}
|
||||
disabled_equipment[i].localised_name = {"", {"equipment-name." .. name}, " (", {"gui-constant.off"}, ")"}
|
||||
disabled_equipment_item[i].placed_as_equipment_result = newname
|
||||
end
|
||||
end
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "Shortcuts",
|
||||
"version": "0.2.0",
|
||||
"version": "0.2.1",
|
||||
"factorio_version": "0.17",
|
||||
"title": "Shortcuts",
|
||||
"author": "npc_strider(morley376)",
|
||||
|
|
|
@ -1,10 +0,0 @@
|
|||
require("shortcuts")
|
||||
data.raw["recipe"]["artillery-targeting-remote"].hidden = true
|
||||
local effect = data.raw["technology"]["artillery"].effects
|
||||
for i=1,(#effect),1 do
|
||||
if effect[i].type == "unlock-recipe" then
|
||||
if effect[i].recipe == "artillery-targeting-remote" then
|
||||
table.remove(effect, i)
|
||||
end
|
||||
end
|
||||
end
|
Binary file not shown.
Before Width: | Height: | Size: 643 B |
Binary file not shown.
Before Width: | Height: | Size: 606 B |
Binary file not shown.
Before Width: | Height: | Size: 712 B |
Binary file not shown.
Before Width: | Height: | Size: 680 B |
|
@ -1,10 +0,0 @@
|
|||
{
|
||||
"name": "Shortcuts",
|
||||
"version": "0.1.0",
|
||||
"factorio_version": "0.17",
|
||||
"title": "Shortcuts",
|
||||
"author": "npc_strider(morley376)",
|
||||
"contact": "",
|
||||
"homepage": "http://steamcommunity.com/id/morley376",
|
||||
"description": "Adds in a shortcut button for the artillery remote, similar to the new personal robot toggle shortcut. Suggest any new shortcut ideas to the discussion page."
|
||||
}
|
|
@ -1,45 +0,0 @@
|
|||
data:extend(
|
||||
{
|
||||
{
|
||||
type = "shortcut",
|
||||
name = "artillery-targeting-remote",
|
||||
order = "a[artillery-targeting-remote]",
|
||||
action = "create-blueprint-item",
|
||||
localised_name = {"item-name.artillery-targeting-remote"},
|
||||
technology_to_unlock = "artillery",
|
||||
item_to_create = "artillery-targeting-remote",
|
||||
style = "red",
|
||||
icon =
|
||||
{
|
||||
filename = "__Shortcuts__/graphics/artillery-targeting-remote-x32-white.png",
|
||||
priority = "extra-high-no-scale",
|
||||
size = 32,
|
||||
scale = 1,
|
||||
flags = {"icon"}
|
||||
},
|
||||
small_icon =
|
||||
{
|
||||
filename = "__Shortcuts__/graphics/artillery-targeting-remote-x24.png",
|
||||
priority = "extra-high-no-scale",
|
||||
size = 24,
|
||||
scale = 1,
|
||||
flags = {"icon"}
|
||||
},
|
||||
disabled_small_icon =
|
||||
{
|
||||
filename = "__Shortcuts__/graphics/artillery-targeting-remote-x24-white.png",
|
||||
priority = "extra-high-no-scale",
|
||||
size = 24,
|
||||
scale = 1,
|
||||
flags = {"icon"}
|
||||
},
|
||||
},
|
||||
-- Custom shortcut can be defined as follows:
|
||||
-- {
|
||||
-- type = "shortcut",
|
||||
-- name = "shortcut-name",
|
||||
-- action = "lua",
|
||||
-- toggleable = true, -- whether or not the shortcut button is a toggle button or not
|
||||
-- order, localised_name, technology_to_unlock, icon, small_icon, disabled_icon, disabled_small_icon as above
|
||||
-- }
|
||||
})
|
Binary file not shown.
Before Width: | Height: | Size: 712 B |
Loading…
Reference in New Issue
Block a user