Archived
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
be669f7b3e | ||
|
|
e49a69058b | ||
|
|
bf22a80ca9 | ||
|
|
14eec22025 | ||
|
|
6290cf9647 | ||
|
|
2aa09fba3d | ||
|
|
ed398933ac | ||
|
|
acbee5c1e7 | ||
|
|
f33d7a6f1b | ||
|
|
8e126bee36 | ||
|
|
59d19f1dd1 | ||
|
|
68503cbf0e | ||
|
|
1a7717e03a |
@@ -1 +1,2 @@
|
|||||||
*.zip
|
*.zip
|
||||||
|
.vscode/*
|
||||||
|
|||||||
+2
-2
@@ -5,9 +5,9 @@ CREDITS
|
|||||||
|
|
||||||
All code and graphics created by Deadlock989, with the following exceptions.
|
All code and graphics created by Deadlock989, with the following exceptions.
|
||||||
|
|
||||||
Code and graphics modifications after 2020-04-08 by Wyrrrd.
|
Code and graphics modifications after 2020-04-08 by Wyrrrd, ickputzdirwech, Friendch and Deadlock989.
|
||||||
For the latest unmodified version, see https://github.com/Wyrrrd/IndustrialDisplayPlates/tree/cd8778eb3b11f8bde5418088253123b1029dc461
|
For the latest unmodified version, see https://github.com/Wyrrrd/IndustrialDisplayPlates/tree/cd8778eb3b11f8bde5418088253123b1029dc461
|
||||||
|
|
||||||
Sounds by thomasevd and Raclure @ freesound.org.
|
Sounds by thomasevd and Raclure @ freesound.org.
|
||||||
|
|
||||||
Thanks to TheStaplergun for getting me started on GUIs and to others for scripting help.
|
Thanks to TheStaplergun for getting me started on GUIs and to others for scripting help.
|
||||||
|
|||||||
@@ -1,12 +1,13 @@
|
|||||||
# Industrial Display Plates
|
# Industrial Display Plates
|
||||||
<img src="https://raw.githubusercontent.com/Wyrrrd/IndustrialDisplayPlates/master/thumbnail.png" width="128" height="128">
|
<img src="https://raw.githubusercontent.com/Wyrrrd/IndustrialDisplayPlates/master/thumbnail.png" width="144" height="144">
|
||||||
|
|
||||||
### Features
|
### Features
|
||||||
Big, medium and small signs to display item and fluid icons. Can be used to blueprint map markers.
|
Big, medium and small signs to display item, fluid and signal icons. Can be used to blueprint map markers.
|
||||||
|
|
||||||
### Locale
|
### Locale
|
||||||
If you want to contribute by translating this mod, you can view the existing translations [here](https://github.com/Wyrrrd/IndustrialDisplayPlates/tree/master/locale). I'd be happy to add your language and credits to the next release.
|
If you want to contribute by translating this mod, you can view the existing translations [here](https://github.com/Wyrrrd/IndustrialDisplayPlates/tree/master/locale). I'd be happy to add your language and credits to the next release.
|
||||||
|
|
||||||
### Credits
|
### Credits
|
||||||
Thanks to [Deadlock989](https://mods.factorio.com/user/Deadlock989) for the [original mod](https://mods.factorio.com/mod/IndustrialDisplays).
|
Thanks to [Deadlock989](https://mods.factorio.com/user/Deadlock989) for the [original mod](https://mods.factorio.com/mod/IndustrialDisplays).
|
||||||
Sounds by thomasevd and Raclure on freesound.org.
|
Sounds by thomasevd and Raclure on freesound.org.
|
||||||
|
Thanks to [Friendch](https://mods.factorio.com/user/Friendch) for the french translation.
|
||||||
@@ -1,4 +1,22 @@
|
|||||||
---------------------------------------------------------------------------------------------------
|
---------------------------------------------------------------------------------------------------
|
||||||
|
Version: 1.1.3
|
||||||
|
Date: 2021-09-06
|
||||||
|
Bugfixes:
|
||||||
|
- Implemented controlled error message for blueprint update bug in factorio to avoid crash
|
||||||
|
---------------------------------------------------------------------------------------------------
|
||||||
|
Version: 1.1.2
|
||||||
|
Date: 2021-08-21
|
||||||
|
Changes:
|
||||||
|
- Made virtual signals available (snouz)
|
||||||
|
- Softer map ping sound
|
||||||
|
Locale:
|
||||||
|
- Adjusted French translation
|
||||||
|
---------------------------------------------------------------------------------------------------
|
||||||
|
Version: 1.1.1
|
||||||
|
Date: 2021-08-08
|
||||||
|
Locale:
|
||||||
|
- Added French translation (thanks to Friendch)
|
||||||
|
---------------------------------------------------------------------------------------------------
|
||||||
Version: 1.1.0
|
Version: 1.1.0
|
||||||
Date: 2020-12-02
|
Date: 2020-12-02
|
||||||
Changes:
|
Changes:
|
||||||
|
|||||||
+20
-4
@@ -37,16 +37,18 @@ end
|
|||||||
|
|
||||||
local function add_map_marker(entity, icon_type, icon_name)
|
local function add_map_marker(entity, icon_type, icon_name)
|
||||||
if icon_type and icon_name then
|
if icon_type and icon_name then
|
||||||
entity.force.add_chart_tag(entity.surface, { icon = { type = icon_type, name = icon_name}, position = entity.position })
|
local map_type = (icon_type == "virtual-signal") and "virtual" or icon_type
|
||||||
|
entity.force.add_chart_tag(entity.surface, { icon = { type = map_type, name = icon_name}, position = entity.position })
|
||||||
entity.surface.play_sound{path = "map-marker-ping", position = entity.position, volume_modifier = 1}
|
entity.surface.play_sound{path = "map-marker-ping", position = entity.position, volume_modifier = 1}
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
local function change_map_markers(entity, icon_type, icon_name)
|
local function change_map_markers(entity, icon_type, icon_name)
|
||||||
|
local map_type = (icon_type == "virtual-signal") and "virtual" or icon_type
|
||||||
local markers = get_map_markers(entity)
|
local markers = get_map_markers(entity)
|
||||||
if markers then
|
if markers then
|
||||||
for _,marker in pairs(markers) do
|
for _,marker in pairs(markers) do
|
||||||
marker.icon = { type = icon_type, name = icon_name}
|
marker.icon = { type = map_type, name = icon_name}
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@@ -74,7 +76,7 @@ local function get_render_sprite_info(entity)
|
|||||||
local id = find_entity_render(entity)
|
local id = find_entity_render(entity)
|
||||||
if id then
|
if id then
|
||||||
local strings = splitstring(rendering.get_sprite(id), "/")
|
local strings = splitstring(rendering.get_sprite(id), "/")
|
||||||
if #strings == 2 then return strings[1], strings[2] end
|
return strings[1], strings[2], strings[1] == 'virtual-signal' and 'virtual' or strings[1]
|
||||||
end
|
end
|
||||||
return nil, nil
|
return nil, nil
|
||||||
end
|
end
|
||||||
@@ -377,7 +379,14 @@ local function create_display_gui(player, selected)
|
|||||||
for prototype_type,prototypes in pairs(DID.elem_prototypes) do
|
for prototype_type,prototypes in pairs(DID.elem_prototypes) do
|
||||||
for _,prototype in pairs(game[prototypes]) do
|
for _,prototype in pairs(game[prototypes]) do
|
||||||
if not DID.displays[prototype.name] and not ((prototype_type == "item" and prototype.has_flag("hidden")) or (prototype_type == "fluid" and prototype.hidden)) then
|
if not DID.displays[prototype.name] and not ((prototype_type == "item" and prototype.has_flag("hidden")) or (prototype_type == "fluid" and prototype.hidden)) then
|
||||||
local group = (prototype.group.name == "fluids") and "intermediate-products" or prototype.group.name
|
local group = ""
|
||||||
|
if prototype_type == "virtual-signal" then
|
||||||
|
group = prototype.subgroup.group.name
|
||||||
|
elseif prototype_type == "fluids" then
|
||||||
|
group = "intermediate-products"
|
||||||
|
else
|
||||||
|
group = prototype.group.name
|
||||||
|
end
|
||||||
if not DID.group_blacklist[group] then
|
if not DID.group_blacklist[group] then
|
||||||
if button_table[group] == nil then button_table[group] = {} end
|
if button_table[group] == nil then button_table[group] = {} end
|
||||||
if button_table[group][prototype.subgroup.name] == nil then button_table[group][prototype.subgroup.name] = {} end
|
if button_table[group][prototype.subgroup.name] == nil then button_table[group][prototype.subgroup.name] = {} end
|
||||||
@@ -543,6 +552,13 @@ script.on_event(defines.events.on_player_setup_blueprint, function (event)
|
|||||||
local blueprint = nil
|
local blueprint = nil
|
||||||
if player and player.blueprint_to_setup and player.blueprint_to_setup.valid_for_read then blueprint = player.blueprint_to_setup
|
if player and player.blueprint_to_setup and player.blueprint_to_setup.valid_for_read then blueprint = player.blueprint_to_setup
|
||||||
elseif player and player.cursor_stack.valid_for_read and player.cursor_stack.name == "blueprint" then blueprint = player.cursor_stack end
|
elseif player and player.cursor_stack.valid_for_read and player.cursor_stack.name == "blueprint" then blueprint = player.cursor_stack end
|
||||||
|
|
||||||
|
-- Workaround for blueprint update bug
|
||||||
|
if blueprint.get_blueprint_entity_count() == 0 then
|
||||||
|
player.print({"display-plates.blueprint-wont-have-icons"})
|
||||||
|
return
|
||||||
|
end
|
||||||
|
|
||||||
if blueprint then
|
if blueprint then
|
||||||
for index,entity in pairs(event.mapping.get()) do
|
for index,entity in pairs(event.mapping.get()) do
|
||||||
local stype,sname = get_render_sprite_info(entity)
|
local stype,sname = get_render_sprite_info(entity)
|
||||||
|
|||||||
@@ -60,7 +60,7 @@ for display,displaydata in pairs(DID.displays) do
|
|||||||
result = display,
|
result = display,
|
||||||
},
|
},
|
||||||
max_health = 10 + size * 30,
|
max_health = 10 + size * 30,
|
||||||
flags = {"placeable-player", "placeable-neutral", "player-creation"},
|
flags = {"placeable-player", "placeable-neutral", "player-creation", "not-rotatable"},
|
||||||
collision_box = { {-box_size+0.1, -box_size+0.1}, {box_size-0.1, box_size-0.1} },
|
collision_box = { {-box_size+0.1, -box_size+0.1}, {box_size-0.1, box_size-0.1} },
|
||||||
selection_box = { {-box_size, -box_size}, {box_size, box_size} },
|
selection_box = { {-box_size, -box_size}, {box_size, box_size} },
|
||||||
collision_mask = {
|
collision_mask = {
|
||||||
|
|||||||
@@ -54,9 +54,11 @@ return {
|
|||||||
elem_prototypes = {
|
elem_prototypes = {
|
||||||
item = "item_prototypes",
|
item = "item_prototypes",
|
||||||
fluid = "fluid_prototypes",
|
fluid = "fluid_prototypes",
|
||||||
|
["virtual-signal"] = "virtual_signal_prototypes",
|
||||||
},
|
},
|
||||||
group_blacklist = {
|
group_blacklist = {
|
||||||
["creative-mod_creative-tools"] = true,
|
["creative-mod_creative-tools"] = true,
|
||||||
|
["other"] = true,
|
||||||
},
|
},
|
||||||
icon_size = 64,
|
icon_size = 64,
|
||||||
icon_mipmaps = 4,
|
icon_mipmaps = 4,
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "IndustrialDisplayPlates",
|
"name": "IndustrialDisplayPlates",
|
||||||
"version": "1.1.0",
|
"version": "1.1.3",
|
||||||
"title": "Industrial Display Plates",
|
"title": "Industrial Display Plates",
|
||||||
"author": "Wyrrrd",
|
"author": "Wyrrrd",
|
||||||
"homepage": "https://github.com/Wyrrrd/IndustrialDisplayPlates",
|
"homepage": "https://github.com/Wyrrrd/IndustrialDisplayPlates",
|
||||||
@@ -8,6 +8,6 @@
|
|||||||
"base >= 1.1.0",
|
"base >= 1.1.0",
|
||||||
"(?)IndustrialRevolution"
|
"(?)IndustrialRevolution"
|
||||||
],
|
],
|
||||||
"description": "Big, medium and small signs which display item and fluid icons. Can be used to blueprint map markers.",
|
"description": "Big, medium and small signs which display item, fluid and signal icons. Can be used to blueprint map markers.",
|
||||||
"factorio_version": "1.1"
|
"factorio_version": "1.1"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,3 +1,6 @@
|
|||||||
|
[display-plates]
|
||||||
|
blueprint-wont-have-icons=Dieser aktualisierte Blaupause wird keine Symbole oder Kartenmarkierungen der Anzeigeplatten enthalten. Um diese hinzuzufügen, erstelle eine neue Blaupause.
|
||||||
|
|
||||||
[entity-name]
|
[entity-name]
|
||||||
copper-display=Kupferanzeigeplatte (groß)
|
copper-display=Kupferanzeigeplatte (groß)
|
||||||
iron-display=Eisenanzeigeplatte (groß)
|
iron-display=Eisenanzeigeplatte (groß)
|
||||||
|
|||||||
@@ -1,3 +1,6 @@
|
|||||||
|
[display-plates]
|
||||||
|
blueprint-wont-have-icons=This updated blueprint will not contain any icons or map markers of the display plates. To include them, create a new blueprint.
|
||||||
|
|
||||||
[entity-name]
|
[entity-name]
|
||||||
copper-display=Copper display plate (large)
|
copper-display=Copper display plate (large)
|
||||||
iron-display=Iron display plate (large)
|
iron-display=Iron display plate (large)
|
||||||
|
|||||||
@@ -0,0 +1,20 @@
|
|||||||
|
[display-plates]
|
||||||
|
blueprint-wont-have-icons=Ce plan mis à jour ne contiendra pas les icônes ni les marqueurs de carte des panneaux d'affichage. Pour les inclure, créez-en un nouveau.
|
||||||
|
|
||||||
|
[entity-name]
|
||||||
|
copper-display=Panneau d'affichage en Cuivre (Grand)
|
||||||
|
iron-display=Panneau d'affichage en Fer (Grand)
|
||||||
|
steel-display=Panneau d'affichage en Acier (Grand)
|
||||||
|
copper-display-medium=Panneau d'affichage en Cuivre (Moyen)
|
||||||
|
iron-display-medium=Panneau d'affichage en Fer (Moyen)
|
||||||
|
steel-display-medium=Panneau d'affichage en Acier (Moyen)
|
||||||
|
copper-display-small=Panneau d'affichage en Cuivre (Petit)
|
||||||
|
iron-display-small=Panneau d'affichage en Fer (Petit)
|
||||||
|
steel-display-small=Panneau d'affichage en Acier (Petit)
|
||||||
|
|
||||||
|
[controls]
|
||||||
|
display-map-marker=Marqueur de carte
|
||||||
|
display-plate=Panneau d'affichage
|
||||||
|
|
||||||
|
[entity-description]
|
||||||
|
display=Une icône qui peut être reliée à un marqueur sur la carte. Les paramètres sont préservés dans les plans.
|
||||||
Binary file not shown.
Reference in New Issue
Block a user