diff --git a/README.md b/README.md index 8933543..6a8423a 100644 --- a/README.md +++ b/README.md @@ -104,12 +104,12 @@ Special thanks to the translators below (in no particular order). * Chinese Simplified (80%) - [jessefjxm](https://crowdin.com/profile/jessefjxm). * Chinese Traditional (34%) - [k98a](https://crowdin.com/profile/k98a). -* Czech (75%) - [dereksp](https://crowdin.com/profile/dereksp), [Meritic](https://crowdin.com/profile/Meritic) and [Treij](https://crowdin.com/profile/Treij). +* Czech (83%) - [dereksp](https://crowdin.com/profile/dereksp), [Meritic](https://crowdin.com/profile/Meritic) and [Treij](https://crowdin.com/profile/Treij). * French (89%) - [Taniotoshi](https://crowdin.com/profile/Taniotoshi) and [daikyraraga](https://crowdin.com/profile/daikyraraga). * German (92%) - [seeba8](https://github.com/seeba8), [ST-DDT](https://crowdin.com/profile/ST-DDT), [LastDawn](https://crowdin.com/profile/LastDawn), [lpzockerx](https://crowdin.com/profile/lpzockerx) and [Leridon](https://crowdin.com/profile/Leridon). * Hungarian (92%) - [mmnetworkteam](https://crowdin.com/profile/mmnetworkteam). * Korean (92%) - [GimoXagros](https://crowdin.com/profile/GimoXagros). -* Polish (99%) - [Tomirad](https://github.com/Tomirad), [Requelfade](https://crowdin.com/profile/Requelfade), [no_desired_username](https://crowdin.com/profile/no_desired_username) and [tomplus](https://crowdin.com/profile/tomplus). +* Polish (100%) - [Tomirad](https://github.com/Tomirad), [Requelfade](https://crowdin.com/profile/Requelfade), [no_desired_username](https://crowdin.com/profile/no_desired_username) and [tomplus](https://crowdin.com/profile/tomplus). * Portuguese, Brazilian (91%) - [celaquila](https://crowdin.com/profile/celaquila). * Russian (99%) - [nastyslave](https://crowdin.com/profile/nastyslave), [diraria](https://crowdin.com/profile/diraria), [scheugen86](https://crowdin.com/profile/scheugen86), [antonus777](https://crowdin.com/profile/antonus777), [schmarotzerltd](https://crowdin.com/profile/schmarotzerltd) and [1avek1](https://crowdin.com/profile/1avek1). * Spanish (92%) - [notallme](https://crowdin.com/profile/notallme). diff --git a/changelog.txt b/changelog.txt index 909cc36..89cbb7b 100644 --- a/changelog.txt +++ b/changelog.txt @@ -1,4 +1,18 @@ --------------------------------------------------------------------------------------------------- +Version: 0.10.4 +Date: 29. 01. 2020 + Added: + - Support for Factorio 0.18.2 audio changes (thanks to AlienXAXS) + Changed: + - Adjusted the vehicle impact sounds of some entities and added more audio variation to match the wider variety now available in the base game + Bugfixes: + - Fixed signal icons not being drawn at the correct scale + - Fixed some items were not showing any icon when using Creative Mod mod + - Minor compatibility fixes to support version 0.5 of Alien Biomes mod + Locales: + - Updated Polish translation (thanks to tomplus) + - Updated Czech translation (thanks to Treij) +--------------------------------------------------------------------------------------------------- Version: 0.10.3 Date: 28. 01. 2020 Added: @@ -144,7 +158,7 @@ Date: 12. 03. 2019 Removed: - Removed custom Landfill tile as 0.17.10 adds this to the base game, existing tiles will be migrated Bugfixes: - - Fixes compatibility with version 4 of Alien Biomes mod + - Fixes compatibility with version 0.4 of Alien Biomes mod Locales: - Added Portuguese, Brazilian translation (thanks to celaquila) - Added Spanish translation (thanks to notallme) diff --git a/info.json b/info.json index f1dd297..38c8a5c 100644 --- a/info.json +++ b/info.json @@ -1,14 +1,14 @@ { "name": "Dectorio", - "version": "0.10.3", + "version": "0.10.4", "title": "Dectorio", "author": "PantherX", "contact": "", "homepage": "https://github.com/jpanther/Dectorio", "factorio_version": "0.18", "dependencies": [ - "base >= 0.18.0", - "? alien-biomes >= 0.4.1", + "base >= 0.18.2", + "? alien-biomes >= 0.5.1", "!Expanded_Color_Lamps", "!Thaumaturgic-Machinations" ], diff --git a/locale/cs/dectorio.cfg b/locale/cs/dectorio.cfg index ea19f42..022fe71 100644 --- a/locale/cs/dectorio.cfg +++ b/locale/cs/dectorio.cfg @@ -42,6 +42,7 @@ dectorio-painted-concrete-speed-modifier=Upravuje základní rychlost chůze a j dectorio-decorative-removal-probability=Pravděpodobnost že ozdoby, keřů a trávy, jsou odstraněny, když podlahové dlaždice jsou umístěny (budou odebrány 1 = 100 % (výchozí hodnota), 0,5 = 50 %, 0 = nebyly odebrány žádné) dectorio-flooring-stack-size=Počet položek podlahy, které lze stohovat v jednom zásob patici (výchozí = 500) dectorio-landscaping-stack-size=Počet terénní úpravy položek, které lze stohovat v jednom zásob patici (výchozí = 500) +dectorio-walls-stack-size=Počet zdí, které mohou být naskládány do jednoho slotu v inventáři (výchozí = 200) [dect-cmd] destroy-orphaned-signs=Odebere všechny osamocené značky z hráče současné povrchu. @@ -53,7 +54,12 @@ sign-cancel=Zrušit [dect-notify] dectorio=Dectorio version=[__1__] Verze __2__ nainstalována. +new-version=[__1__] Aktualizováno z verze __2__ na verzi __3__. Podrobnosti naleznete v protokolu změn (Mods > Dectorio > Changelog). incompatible=[__1__] Varování: Byl detekován nekompatibilní mod! +reason-signals=[__1__] Důvod: "__2__" přepíše data signálu. +reason-tech=[__1__] Důvod: "__2__" duplikuje technologii, která se již nachází v módu Dectorio. +reason-item=[__1__] Důvod: "__2__" duplikuje technologii, která se již nachází v módu Dectorio. +reason-disable=[__1__] Důvod: "__2__" deaktivuje funkci, která je přidaná módem Dectorio. mod-portal=[__1__] Přejděte na portál modu pro bližší informace. supported-mod-added=[__1__] Přidána podpora pro __2__. supported-mod-removed=[__1__] Odstraněna podpora pro __2__ . @@ -122,6 +128,7 @@ dect-small-lamp-glow=Když tato lampa zaznamená signál, tak se rozsvítí siln [recipe-name] dect-concrete-wall-from-stone-wall=Betonová zeď z kamenné zdi +dect-concrete-gate-from-stone-gate=Betonová brána z kamenné brány [entity-name] dect-wood-wall=Dřevěná barikáda diff --git a/locale/pl/dectorio.cfg b/locale/pl/dectorio.cfg index d58a3e2..8c140c6 100644 --- a/locale/pl/dectorio.cfg +++ b/locale/pl/dectorio.cfg @@ -149,6 +149,7 @@ dect-lawnmower=Przeciągnij przytrzymując __CONTROL__select-for-blueprint__, ab [recipe-name] dect-concrete-wall-from-stone-wall=Betonowy mur z kamiennego muru +dect-concrete-gate-from-stone-gate=Betonowa brama z kamiennej bramy [entity-name] dect-wood-wall=Drewniana barykada diff --git a/prototypes/entity/decoratives.lua b/prototypes/entity/decoratives.lua index 6211581..bc53449 100644 --- a/prototypes/entity/decoratives.lua +++ b/prototypes/entity/decoratives.lua @@ -1,41 +1,45 @@ -- entity/decoratives if DECT.ENABLED["decoratives"] then + -- Pull in the base entity sounds + local sounds = require("__base__.prototypes.entity.demo-sounds") - data:extend({ + data:extend( { - type = "simple-entity-with-force", - name = "dect-traffic-bollard", - icon = "__Dectorio__/graphics/icons/traffic-bollard.png", - icon_size = 32, - flags = {"placeable-neutral", "placeable-player", "player-creation"}, - render_layer = "object", - minable = {hardness = 0.2, mining_time = 0.3, result = "dect-traffic-bollard", count = 1}, - max_health = 120, - corpse = "small-remnants", - collision_box = {{-0.15, -0.15}, {0.25, 0.15}}, - selection_box = {{-0.25, -1.4}, {0.25, 0.16}}, - repair_sound = { filename = "__base__/sound/manual-repair-simple.ogg" }, - mined_sound = { filename = "__core__/sound/deconstruct-small.ogg" }, - vehicle_impact_sound = {filename = "__base__/sound/car-metal-impact.ogg", volume = 0.7}, - pictures = { - { - filename = "__Dectorio__/graphics/decoratives/traffic-bollard/traffic-bollard.png", - priority = "extra-high", - width = 35, - height = 42, - shift = {0.4, -0.6}, - hr_version = { - filename = "__Dectorio__/graphics/decoratives/traffic-bollard/hr-traffic-bollard.png", + { + type = "simple-entity-with-force", + name = "dect-traffic-bollard", + icon = "__Dectorio__/graphics/icons/traffic-bollard.png", + icon_size = 64, + icon_mipmaps = 1, + flags = {"placeable-neutral", "placeable-player", "player-creation"}, + render_layer = "object", + minable = {hardness = 0.2, mining_time = 0.3, result = "dect-traffic-bollard", count = 1}, + max_health = 120, + corpse = "small-remnants", + collision_box = {{-0.15, -0.15}, {0.25, 0.15}}, + selection_box = {{-0.25, -1.4}, {0.25, 0.16}}, + repair_sound = {filename = "__base__/sound/manual-repair-simple.ogg"}, + mined_sound = {filename = "__core__/sound/deconstruct-small.ogg"}, + vehicle_impact_sound = sounds.generic_impact, + pictures = { + { + filename = "__Dectorio__/graphics/decoratives/traffic-bollard/traffic-bollard.png", priority = "extra-high", - width = 70, - height = 84, + width = 35, + height = 42, shift = {0.4, -0.6}, - scale = 0.5 + hr_version = { + filename = "__Dectorio__/graphics/decoratives/traffic-bollard/hr-traffic-bollard.png", + priority = "extra-high", + width = 70, + height = 84, + shift = {0.4, -0.6}, + scale = 0.5 + } } } } } - }) - + ) end diff --git a/prototypes/entity/signs.lua b/prototypes/entity/signs.lua index 29290ef..99e6c7e 100644 --- a/prototypes/entity/signs.lua +++ b/prototypes/entity/signs.lua @@ -1,74 +1,79 @@ -- entity/signs if DECT.ENABLED["signs"] then + -- Pull in the base entity sounds + local sounds = require("__base__.prototypes.entity.demo-sounds") - data:extend({ + data:extend( { - type = "simple-entity", - name = "dect-sign-wood", - icon = "__Dectorio__/graphics/icons/sign-wood.png", - icon_size = 32, - flags = {"placeable-neutral"}, - render_layer = "object", - minable = {mining_time = 0.2, result = "dect-sign-wood", count = 1}, - max_health = 40, - collision_box = {{-0.15, -0.15}, {0.15, 0.15}}, - selection_box = {{-0.5, -0.5}, {0.5, 0.5}}, - drawing_box = {{-0.5, -1.6}, {0.5, 0.5}}, - repair_sound = { filename = "__base__/sound/manual-repair-simple.ogg" }, - mined_sound = { filename = "__Dectorio__/sound/deconstruct-wood.ogg" }, - vehicle_impact_sound = {filename = "__base__/sound/car-wood-impact.ogg", volume = 1.0}, - pictures = { - { - filename = "__Dectorio__/graphics/entity/sign-wood/sign-wood.png", - priority = "extra-high", - width = 85, - height = 65, - shift = {0.8, -0.45}, - hr_version = { - filename = "__Dectorio__/graphics/entity/sign-wood/hr-sign-wood.png", + { + type = "simple-entity", + name = "dect-sign-wood", + icon = "__Dectorio__/graphics/icons/sign-wood.png", + icon_size = 64, + icon_mipmaps = 1, + flags = {"placeable-neutral"}, + render_layer = "object", + minable = {mining_time = 0.2, result = "dect-sign-wood", count = 1}, + max_health = 40, + collision_box = {{-0.15, -0.15}, {0.15, 0.15}}, + selection_box = {{-0.5, -0.5}, {0.5, 0.5}}, + drawing_box = {{-0.5, -1.6}, {0.5, 0.5}}, + repair_sound = {filename = "__base__/sound/manual-repair-simple.ogg"}, + mined_sound = {filename = "__Dectorio__/sound/deconstruct-wood.ogg"}, + vehicle_impact_sound = {filename = "__base__/sound/car-wood-impact.ogg", volume = 1.0}, + pictures = { + { + filename = "__Dectorio__/graphics/entity/sign-wood/sign-wood.png", priority = "extra-high", - width = 170, - height = 130, + width = 85, + height = 65, shift = {0.8, -0.45}, - scale = 0.5 + hr_version = { + filename = "__Dectorio__/graphics/entity/sign-wood/hr-sign-wood.png", + priority = "extra-high", + width = 170, + height = 130, + shift = {0.8, -0.45}, + scale = 0.5 + } } } - } - }, - { - type = "simple-entity", - name = "dect-sign-steel", - icon = "__Dectorio__/graphics/icons/sign-steel.png", - icon_size = 32, - flags = {"placeable-neutral"}, - render_layer = "object", - minable = {mining_time = 0.2, result = "dect-sign-steel", count = 1}, - max_health = 65, - collision_box = {{-0.15, -0.15}, {0.15, 0.15}}, - selection_box = {{-0.5, -0.5}, {0.5, 0.5}}, - drawing_box = {{-0.5, -1.6}, {0.5, 0.5}}, - repair_sound = { filename = "__base__/sound/manual-repair-simple.ogg" }, - mined_sound = { filename = "__base__/sound/deconstruct-bricks.ogg" }, - vehicle_impact_sound = {filename = "__base__/sound/car-metal-impact.ogg", volume = 1.0}, - pictures = { - { - filename = "__Dectorio__/graphics/entity/sign-steel/sign-steel.png", - priority = "extra-high", - width = 85, - height = 65, - shift = {0.77, -0.45}, - hr_version = { - filename = "__Dectorio__/graphics/entity/sign-steel/hr-sign-steel.png", + }, + { + type = "simple-entity", + name = "dect-sign-steel", + icon = "__Dectorio__/graphics/icons/sign-steel.png", + icon_size = 64, + icon_mipmaps = 1, + flags = {"placeable-neutral"}, + render_layer = "object", + minable = {mining_time = 0.2, result = "dect-sign-steel", count = 1}, + max_health = 65, + collision_box = {{-0.15, -0.15}, {0.15, 0.15}}, + selection_box = {{-0.5, -0.5}, {0.5, 0.5}}, + drawing_box = {{-0.5, -1.6}, {0.5, 0.5}}, + repair_sound = {filename = "__base__/sound/manual-repair-simple.ogg"}, + mined_sound = {filename = "__base__/sound/deconstruct-bricks.ogg"}, + vehicle_impact_sound = sounds.generic_impact, + pictures = { + { + filename = "__Dectorio__/graphics/entity/sign-steel/sign-steel.png", priority = "extra-high", - width = 170, - height = 130, - shift = {0.77, -0.43}, - scale = 0.5 + width = 85, + height = 65, + shift = {0.77, -0.45}, + hr_version = { + filename = "__Dectorio__/graphics/entity/sign-steel/hr-sign-steel.png", + priority = "extra-high", + width = 170, + height = 130, + shift = {0.77, -0.43}, + scale = 0.5 + } } } } } - }) - + ) end diff --git a/prototypes/entity/walls.lua b/prototypes/entity/walls.lua index 94bd5d0..255c7b6 100644 --- a/prototypes/entity/walls.lua +++ b/prototypes/entity/walls.lua @@ -1,6 +1,9 @@ -- entity/walls if DECT.ENABLED["walls"] then + -- Pull in the base entity sounds + local sounds = require("__base__.prototypes.entity.demo-sounds") + -- Make a copy of the base stone wall before clearing it out local base_stone_wall = data.raw["wall"]["stone-wall"] data.raw["wall"]["stone-wall"] = nil @@ -23,7 +26,7 @@ if DECT.ENABLED["walls"] then corpse = "wall-remnants", repair_sound = {filename = "__base__/sound/manual-repair-simple.ogg"}, mined_sound = {filename = "__base__/sound/deconstruct-bricks.ogg"}, - vehicle_impact_sound = {filename = "__base__/sound/car-stone-impact.ogg", volume = 1.0}, + vehicle_impact_sound = sounds.car_stone_impact, connected_gate_visualization = { filename = "__core__/graphics/arrows/underground-lines.png", priority = "high", @@ -514,7 +517,7 @@ if DECT.ENABLED["walls"] then corpse = "wall-remnants", repair_sound = {filename = "__base__/sound/manual-repair-simple.ogg"}, mined_sound = {filename = "__base__/sound/deconstruct-bricks.ogg"}, - vehicle_impact_sound = {filename = "__base__/sound/car-stone-impact.ogg", volume = 1.0}, + vehicle_impact_sound = sounds.car_stone_impact, connected_gate_visualization = { filename = "__core__/graphics/arrows/underground-lines.png", priority = "high", @@ -578,7 +581,7 @@ if DECT.ENABLED["walls"] then corpse = "wall-remnants", repair_sound = {filename = "__base__/sound/manual-repair-simple.ogg"}, mined_sound = {filename = "__base__/sound/deconstruct-bricks.ogg"}, - vehicle_impact_sound = {filename = "__base__/sound/car-stone-impact.ogg", volume = 1.0}, + vehicle_impact_sound = sounds.generic_impact, connected_gate_visualization = { filename = "__core__/graphics/arrows/underground-lines.png", priority = "high", @@ -1623,7 +1626,7 @@ if DECT.ENABLED["walls"] then } } }, - vehicle_impact_sound = generic_impact_sound(), + vehicle_impact_sound = sounds.car_stone_impact, open_sound = base_gate.open_sound, close_sound = base_gate.close_sound }, @@ -1656,7 +1659,7 @@ if DECT.ENABLED["walls"] then vertical_rail_base = base_gate.vertical_rail_base, horizontal_rail_base = base_gate.horizontal_rail_base, wall_patch = base_gate.wall_patch, - vehicle_impact_sound = generic_impact_sound(), + vehicle_impact_sound = sounds.generic_impact, open_sound = base_gate.open_sound, close_sound = base_gate.close_sound } diff --git a/prototypes/item/decoratives.lua b/prototypes/item/decoratives.lua index 2a00ffa..813b690 100644 --- a/prototypes/item/decoratives.lua +++ b/prototypes/item/decoratives.lua @@ -1,28 +1,31 @@ -- item/decoratives if DECT.ENABLED["decoratives"] then - -- Add subgroup for decoratives - data:extend({ + data:extend( { - type = "item-subgroup", - name = "decoratives", - group = DECT.ITEM_GROUP, - order = "e-b" + { + type = "item-subgroup", + name = "decoratives", + group = DECT.ITEM_GROUP, + order = "e-b" + } } - }) + ) - data:extend({ + data:extend( { - type = "item", - name = "dect-traffic-bollard", - icon = "__Dectorio__/graphics/icons/traffic-bollard.png", - icon_size = 64, - subgroup = "decoratives", - order = "a[traffic-bollard]", - place_result = "dect-traffic-bollard", - stack_size = 50 + { + type = "item", + name = "dect-traffic-bollard", + icon = "__Dectorio__/graphics/icons/traffic-bollard.png", + icon_size = 64, + icon_mipmaps = 1, + subgroup = "decoratives", + order = "a[traffic-bollard]", + place_result = "dect-traffic-bollard", + stack_size = 50 + } } - }) - + ) end diff --git a/prototypes/item/flooring.lua b/prototypes/item/flooring.lua index c4409cb..efa7273 100644 --- a/prototypes/item/flooring.lua +++ b/prototypes/item/flooring.lua @@ -1,14 +1,16 @@ -- item/flooring -- Add new subgroup for basic floorings -data:extend({ +data:extend( { - type = "item-subgroup", - name = "flooring-basic", - group = DECT.ITEM_GROUP, - order = "i-b" + { + type = "item-subgroup", + name = "flooring-basic", + group = DECT.ITEM_GROUP, + order = "i-b" + } } -}) +) -- Change base concrete & stone path local base_refined_concrete = data.raw["item"]["refined-concrete"] @@ -25,65 +27,74 @@ base_stone_brick.subgroup = "flooring-basic" base_stone_brick.order = "00[b-stone-brick]" if DECT.ENABLED["painted-concrete"] then - -- Add new subgroup for painted concretes - data:extend({ + data:extend( { - type = "item-subgroup", - name = "flooring-painted", - group = DECT.ITEM_GROUP, - order = "i-c" + { + type = "item-subgroup", + name = "flooring-painted", + group = DECT.ITEM_GROUP, + order = "i-c" + } } - }) + ) -- Add new items for _, variant in pairs(DECT.CONFIG.PAINT_VARIANTS) do - data:extend({ + data:extend( { - type = "item", - name = "dect-paint-"..variant.name, - icon = "__Dectorio__/graphics/icons/paint-"..variant.name..".png", - icon_size = 64, - subgroup = "flooring-painted", - order = "00[b-".._.."-paint-"..variant.name.."]", - stack_size = DECT.CONFIG.SETTINGS["flooring_stack_size"], - place_as_tile = { - result = "dect-paint-"..variant.name.."-left", - condition_size = 1, - condition = { "water-tile" } + { + type = "item", + name = "dect-paint-" .. variant.name, + icon = "__Dectorio__/graphics/icons/paint-" .. variant.name .. ".png", + icon_size = 64, + icon_mipmaps = 1, + subgroup = "flooring-painted", + order = "00[b-" .. _ .. "-paint-" .. variant.name .. "]", + stack_size = DECT.CONFIG.SETTINGS["flooring_stack_size"], + place_as_tile = { + result = "dect-paint-" .. variant.name .. "-left", + condition_size = 1, + condition = {"water-tile"} + } } } - }) + ) end -- Add new subgroup for refined painted concretes - data:extend({ + data:extend( { - type = "item-subgroup", - name = "flooring-painted-refined", - group = DECT.ITEM_GROUP, - order = "i-d" + { + type = "item-subgroup", + name = "flooring-painted-refined", + group = DECT.ITEM_GROUP, + order = "i-d" + } } - }) + ) -- Add new items for _, variant in pairs(DECT.CONFIG.PAINT_VARIANTS) do - data:extend({ + data:extend( { - type = "item", - name = "dect-paint-refined-"..variant.name, - icon = "__Dectorio__/graphics/icons/paint-"..variant.name.."-refined.png", - icon_size = 64, - subgroup = "flooring-painted-refined", - order = "00[b-".._.."-paint-refined-"..variant.name.."]", - stack_size = DECT.CONFIG.SETTINGS["flooring_stack_size"], - place_as_tile = { - result = "dect-paint-refined-"..variant.name.."-left", - condition_size = 1, - condition = { "water-tile" } + { + type = "item", + name = "dect-paint-refined-" .. variant.name, + icon = "__Dectorio__/graphics/icons/paint-" .. variant.name .. "-refined.png", + icon_size = 64, + icon_mipmaps = 1, + subgroup = "flooring-painted-refined", + order = "00[b-" .. _ .. "-paint-refined-" .. variant.name .. "]", + stack_size = DECT.CONFIG.SETTINGS["flooring_stack_size"], + place_as_tile = { + result = "dect-paint-refined-" .. variant.name .. "-left", + condition_size = 1, + condition = {"water-tile"} + } } } - }) + ) end -- Move base hazard concrete item under painted concrete @@ -99,12 +110,12 @@ if DECT.ENABLED["painted-concrete"] then if not DECT.CONFIG.SETTINGS["vanilla_hazard_concrete"] then base_hazard_item.icon = "__Dectorio__/graphics/icons/paint-hazard.png" base_hazard_item.icon_size = 64 + base_hazard_item.icon_mipmaps = 1 base_refined_hazard_item.icon = "__Dectorio__/graphics/icons/paint-hazard-refined.png" base_refined_hazard_item.icon_size = 64 + base_refined_hazard_item.icon_mipmaps = 1 end - else - -- Move base hazard concrete item under basic flooring local base_hazard_item = data.raw["item"]["hazard-concrete"] base_hazard_item.subgroup = "flooring-basic" @@ -114,75 +125,77 @@ else base_refined_hazard_item.subgroup = "flooring-basic" base_refined_hazard_item.order = "00[f-refined-hazard-concrete]" base_refined_hazard_item.stack_size = DECT.CONFIG.SETTINGS["flooring_stack_size"] - end if DECT.ENABLED["wood-floor"] then - - data:extend({ + data:extend( { - type = "item", - name = "dect-wood-floor", - icon = "__Dectorio__/graphics/icons/wood-floor.png", - icon_size = 64, - fuel_category = "chemical", - fuel_value = "2MJ", - subgroup = "flooring-basic", - order = "00[a-wood-floor]", - stack_size = DECT.CONFIG.SETTINGS["flooring_stack_size"], - place_as_tile = { - result = "dect-wood-floor", - condition_size = 1, - condition = { "water-tile" } + { + type = "item", + name = "dect-wood-floor", + icon = "__Dectorio__/graphics/icons/wood-floor.png", + icon_size = 64, + icon_mipmaps = 1, + fuel_category = "chemical", + fuel_value = "2MJ", + subgroup = "flooring-basic", + order = "00[a-wood-floor]", + stack_size = DECT.CONFIG.SETTINGS["flooring_stack_size"], + place_as_tile = { + result = "dect-wood-floor", + condition_size = 1, + condition = {"water-tile"} + } } } - }) - + ) end if DECT.ENABLED["concrete"] then - - data:extend({ + data:extend( { - type = "item", - name = "dect-concrete-grid", - icon = "__Dectorio__/graphics/icons/concrete-grid.png", - icon_size = 64, - subgroup = "flooring-basic", - order = "00[f-concrete-grid]", - stack_size = DECT.CONFIG.SETTINGS["flooring_stack_size"], - place_as_tile = { - result = "dect-concrete-grid", - condition_size = 1, - condition = { "water-tile" } + { + type = "item", + name = "dect-concrete-grid", + icon = "__Dectorio__/graphics/icons/concrete-grid.png", + icon_size = 64, + icon_mipmaps = 1, + subgroup = "flooring-basic", + order = "00[f-concrete-grid]", + stack_size = DECT.CONFIG.SETTINGS["flooring_stack_size"], + place_as_tile = { + result = "dect-concrete-grid", + condition_size = 1, + condition = {"water-tile"} + } } } - }) - + ) end if DECT.ENABLED["gravel"] then - -- Add new items for _, variant in pairs(DECT.CONFIG.GRAVEL_VARIANTS) do - data:extend({ + data:extend( { - type = "item", - name = "dect-"..variant.name.."-gravel", - icons = { - { icon = "__Dectorio__/graphics/icons/gravel.png", tint = variant.color }, - }, - icon_size = 64, - subgroup = "flooring-basic", - order = "00[g-gravel-"..variant.name.."]", - stack_size = DECT.CONFIG.SETTINGS["flooring_stack_size"], - place_as_tile = { - result = "dect-"..variant.name.."-gravel", - condition_size = 2, - condition = { "water-tile" } + { + type = "item", + name = "dect-" .. variant.name .. "-gravel", + icons = { + {icon = "__Dectorio__/graphics/icons/gravel.png", tint = variant.color} + }, + icon_size = 64, + icon_mipmaps = 1, + subgroup = "flooring-basic", + order = "00[g-gravel-" .. variant.name .. "]", + stack_size = DECT.CONFIG.SETTINGS["flooring_stack_size"], + place_as_tile = { + result = "dect-" .. variant.name .. "-gravel", + condition_size = 2, + condition = {"water-tile"} + } } } - }) + ) end - end diff --git a/prototypes/item/landscaping.lua b/prototypes/item/landscaping.lua index f18f6b5..f99bb9c 100644 --- a/prototypes/item/landscaping.lua +++ b/prototypes/item/landscaping.lua @@ -1,180 +1,190 @@ -- item/landscaping if DECT.ENABLED["landscaping"] then - -- Add subgroup for base tiles - data:extend({ + data:extend( { - type = "item-subgroup", - name = "landscaping", - group = DECT.ITEM_GROUP, - order = "l-a" + { + type = "item-subgroup", + name = "landscaping", + group = DECT.ITEM_GROUP, + order = "l-a" + } } - }) + ) -- Add new items local base_tiles = DECT.CONFIG.BASE_TILES for _, tile in pairs(base_tiles) do - data:extend({ + data:extend( { - type = "item", - name = "dect-base-"..tile, - icon = "__Dectorio__/graphics/icons/base-"..tile..".png", - icon_size = 64, - subgroup = "landscaping", - order = "a[base-"..tile.."]", - stack_size = DECT.CONFIG.SETTINGS["landscaping_stack_size"], - place_as_tile = { - result = tile, - condition_size = 1, - condition = { "water-tile" } - }, - localised_name = {"tile-name."..tile} + { + type = "item", + name = "dect-base-" .. tile, + icon = "__Dectorio__/graphics/icons/base-" .. tile .. ".png", + icon_size = 64, + subgroup = "landscaping", + order = "a[base-" .. tile .. "]", + stack_size = DECT.CONFIG.SETTINGS["landscaping_stack_size"], + place_as_tile = { + result = tile, + condition_size = 1, + condition = {"water-tile"} + }, + localised_name = {"tile-name." .. tile} + } } - }) + ) end - end if DECT.ENABLED["waterfill"] or DECT.ENABLED["landscaping"] then - -- Add subgroup for base water - data:extend({ + data:extend( { - type = "item-subgroup", - name = "landscaping-earthworks", - group = DECT.ITEM_GROUP, - order = "l-b" + { + type = "item-subgroup", + name = "landscaping-earthworks", + group = DECT.ITEM_GROUP, + order = "l-b" + } } - }) - + ) end if DECT.ENABLED["waterfill"] then - -- Add new items local water_tiles = DECT.CONFIG.BASE_WATER_TILES for _, tile in pairs(water_tiles) do - data:extend({ + data:extend( { - type = "item", - name = "dect-base-"..tile, - icon = "__Dectorio__/graphics/icons/base-"..tile..".png", - icon_size = 64, - subgroup = "landscaping-earthworks", - order = "a[".._.."base-"..tile.."]", - stack_size = DECT.CONFIG.SETTINGS["landscaping_stack_size"], - place_as_tile = { - result = tile, - condition_size = 1, - condition = { "water-tile" } - }, - localised_name = {"tile-name."..tile} + { + type = "item", + name = "dect-base-" .. tile, + icon = "__Dectorio__/graphics/icons/base-" .. tile .. ".png", + icon_size = 64, + subgroup = "landscaping-earthworks", + order = "a[" .. _ .. "base-" .. tile .. "]", + stack_size = DECT.CONFIG.SETTINGS["landscaping_stack_size"], + place_as_tile = { + result = tile, + condition_size = 1, + condition = {"water-tile"} + }, + localised_name = {"tile-name." .. tile} + } } - }) + ) -- If this is deep water, then it can only be placed in water if string.find(tile, "deep") then - data.raw["item"]["dect-base-"..tile].place_as_tile.condition = { "ground-tile" } + data.raw["item"]["dect-base-" .. tile].place_as_tile.condition = {"ground-tile"} end end - end if DECT.ENABLED["landscaping"] then - -- Add subgroup for base trees - data:extend({ + data:extend( { - type = "item-subgroup", - name = "landscaping-trees", - group = DECT.ITEM_GROUP, - order = "l-c" + { + type = "item-subgroup", + name = "landscaping-trees", + group = DECT.ITEM_GROUP, + order = "l-c" + } } - }) + ) -- Add items for placing trees local base_trees = DECT.CONFIG.BASE_TREES for _, tree in pairs(base_trees) do - data:extend({ + data:extend( { - type = "item", - name = "dect-base-"..tree, - icon = data.raw["tree"][tree].icon, - icon_size = 64, - icon_mipmaps = 4, - subgroup = "landscaping-trees", - order = "a[base-"..tree.."]", - stack_size = DECT.CONFIG.SETTINGS["landscaping_stack_size"], - place_result = tree, - localised_name = {"entity-name."..tree} + { + type = "item", + name = "dect-base-" .. tree, + icon = data.raw["tree"][tree].icon, + icon_size = 64, + icon_mipmaps = 4, + subgroup = "landscaping-trees", + order = "a[base-" .. tree .. "]", + stack_size = DECT.CONFIG.SETTINGS["landscaping_stack_size"], + place_result = tree, + localised_name = {"entity-name." .. tree} + } } - }) + ) end -- Add subgroup for base rocks - data:extend({ + data:extend( { - type = "item-subgroup", - name = "landscaping-rocks", - group = DECT.ITEM_GROUP, - order = "l-d" + { + type = "item-subgroup", + name = "landscaping-rocks", + group = DECT.ITEM_GROUP, + order = "l-d" + } } - }) + ) -- Add items for placing rocks local base_rocks = DECT.CONFIG.BASE_ROCKS for _, rock in pairs(base_rocks) do - data:extend({ + data:extend( { - type = "item", - name = "dect-base-"..rock, - icon = data.raw["simple-entity"][rock].icon, - icon_size = 64, - icon_mipmaps = 4, - subgroup = "landscaping-rocks", - order = "a[base-"..rock.."]", - stack_size = DECT.CONFIG.SETTINGS["landscaping_stack_size"], - place_result = rock, - localised_name = {"entity-name."..rock} + { + type = "item", + name = "dect-base-" .. rock, + icon = data.raw["simple-entity"][rock].icon, + icon_size = 64, + icon_mipmaps = 4, + subgroup = "landscaping-rocks", + order = "a[base-" .. rock .. "]", + stack_size = DECT.CONFIG.SETTINGS["landscaping_stack_size"], + place_result = rock, + localised_name = {"entity-name." .. rock} + } } - }) + ) end -- Add Lawnmower item - data:extend({ - { - type = "selection-tool", - name = "dect-lawnmower", - icon = "__Dectorio__/graphics/icons/lawnmower.png", - icon_size = 64, - stack_size = 1, - stackable = false, - subgroup = "landscaping-earthworks", - order = "d[lawnmower]", - selection_color = {r=0.10, g=0.46, b=0.13, a=0.33}, - alt_selection_color = {r=0.72, g=0.69, b=0.17, a=0.33}, - selection_mode = {"any-entity"}, - alt_selection_mode = {"nothing"}, - selection_cursor_box_type = "not-allowed", - alt_selection_cursor_box_type = "entity", - can_be_mod_opened = false, - show_in_library = false - }, + data:extend( { - type = "sound", - name = "dect-lawnmower", - variations = { - { filename = "__Dectorio__/sound/lawnmower-01.ogg", volume = 0.9 }, - { filename = "__Dectorio__/sound/lawnmower-02.ogg", volume = 1 } + { + type = "selection-tool", + name = "dect-lawnmower", + icon = "__Dectorio__/graphics/icons/lawnmower.png", + icon_size = 64, + icon_mipmaps = 1, + stack_size = 1, + stackable = false, + subgroup = "landscaping-earthworks", + order = "d[lawnmower]", + selection_color = {r = 0.10, g = 0.46, b = 0.13, a = 0.33}, + alt_selection_color = {r = 0.72, g = 0.69, b = 0.17, a = 0.33}, + selection_mode = {"any-entity"}, + alt_selection_mode = {"nothing"}, + selection_cursor_box_type = "not-allowed", + alt_selection_cursor_box_type = "entity", + can_be_mod_opened = false, + show_in_library = false + }, + { + type = "sound", + name = "dect-lawnmower", + variations = { + {filename = "__Dectorio__/sound/lawnmower-01.ogg", volume = 0.9}, + {filename = "__Dectorio__/sound/lawnmower-02.ogg", volume = 1} + } } } - }) - + ) end if DECT.ENABLED["waterfill"] or DECT.ENABLED["landscaping"] then - -- Modify base landfill and cliff explosives local base_landfill = data.raw["item"]["landfill"] local base_cliff_explosives = data.raw["capsule"]["cliff-explosives"] @@ -183,5 +193,4 @@ if DECT.ENABLED["waterfill"] or DECT.ENABLED["landscaping"] then base_landfill.stack_size = DECT.CONFIG.SETTINGS["landscaping_stack_size"] base_cliff_explosives.subgroup = "landscaping-earthworks" base_cliff_explosives.order = "c[cliff-explosives]" - end diff --git a/prototypes/item/signs.lua b/prototypes/item/signs.lua index 9663f54..81f434d 100644 --- a/prototypes/item/signs.lua +++ b/prototypes/item/signs.lua @@ -1,38 +1,42 @@ -- item/signs if DECT.ENABLED["signs"] then - -- Add subgroup for signs - data:extend({ + data:extend( { - type = "item-subgroup", - name = "signs", - group = DECT.ITEM_GROUP, - order = "0" + { + type = "item-subgroup", + name = "signs", + group = DECT.ITEM_GROUP, + order = "0" + } } - }) + ) - data:extend({ - { - type = "item", - name = "dect-sign-wood", - icon = "__Dectorio__/graphics/icons/sign-wood.png", - icon_size = 64, - subgroup = "signs", - order = "a[sign-wood]", - place_result = "dect-sign-wood", - stack_size = 50 - }, + data:extend( { - type = "item", - name = "dect-sign-steel", - icon = "__Dectorio__/graphics/icons/sign-steel.png", - icon_size = 64, - subgroup = "signs", - order = "b[sign-steel]", - place_result = "dect-sign-steel", - stack_size = 50 + { + type = "item", + name = "dect-sign-wood", + icon = "__Dectorio__/graphics/icons/sign-wood.png", + icon_size = 64, + icon_mipmaps = 1, + subgroup = "signs", + order = "a[sign-wood]", + place_result = "dect-sign-wood", + stack_size = 50 + }, + { + type = "item", + name = "dect-sign-steel", + icon = "__Dectorio__/graphics/icons/sign-steel.png", + icon_size = 64, + icon_mipmaps = 1, + subgroup = "signs", + order = "b[sign-steel]", + place_result = "dect-sign-steel", + stack_size = 50 + } } - }) - + ) end diff --git a/prototypes/signal/signals.lua b/prototypes/signal/signals.lua index 3d8836a..746b4f8 100755 --- a/prototypes/signal/signals.lua +++ b/prototypes/signal/signals.lua @@ -1,11 +1,10 @@ -- signal/signals local function char(num) - return string.char(string.byte("a")+num-1) + return string.char(string.byte("a") + num - 1) end if DECT.ENABLED["signals"] then - -- Coloured signals -- ---------- @@ -26,26 +25,29 @@ if DECT.ENABLED["signals"] then -- Create new virtual colour items if they don't already exist for i, color in pairs(colors) do if color.type == "virtual" then - local tint = {r=color.color.r, g=color.color.g, b=color.color.b, a=0.70} - data:extend({ + local tint = {r = color.color.r, g = color.color.g, b = color.color.b, a = 0.70} + data:extend( { - type = "virtual-signal", - name = color.name, - icons = { - { icon = "__base__/graphics/icons/signal/signal_grey.png", tint = tint } - }, - icon_size = 32, - subgroup = "virtual-signal-color", - order = "d[colors]-0["..char(i).."-"..color.name.."]" + { + type = "virtual-signal", + name = color.name, + icons = { + {icon = "__base__/graphics/icons/signal/signal_grey.png", tint = tint} + }, + icon_size = 64, + icon_mipmaps = 4, + subgroup = "virtual-signal-color", + order = "d[colors]-0[" .. char(i) .. "-" .. color.name .. "]" + } } - }) + ) end end -- Reset black signal to 'correct' icon if data.raw["virtual-signal"]["signal-black"] then local black = data.raw["virtual-signal"]["signal-black"] - black.icons[1].tint = {r=0.16,g=0.16,b=0.16,a=0.70} + black.icons[1].tint = {r = 0.16, g = 0.16, b = 0.16, a = 0.70} end -- Update the lamps @@ -57,55 +59,85 @@ if DECT.ENABLED["signals"] then -- local lamp_glow = data.raw.lamp["dect-small-lamp-glow"] -- lamp_glow.signal_to_color_mapping = colors - -- Icon signals -- ---------- local iconsets = { ["arrow"] = { name = "arrow", - background = {r=1.00,g=0.58,b=0.14,a=0.2}, + background = {r = 1.00, g = 0.58, b = 0.14, a = 0.2}, order = "eb", icons = {"down", "up", "left", "right", "vertical", "horizontal", "universal", "reset"} }, - ["misc"] = { + ["misc"] = { name = "misc", - background = {r=0.65,g=0.38,b=0.99,a=0.2}, + background = {r = 0.65, g = 0.38, b = 0.99, a = 0.2}, order = "ea", - icons = {"clock", "alarm", "battery", "power", "nuclear", "rocket", "temperature", "finish", "gears", "star", "light", "mine", "oil", "gun", "tank", "train", "wall", "siren", "warning-shield", "warning-triangle"} - }, + icons = { + "clock", + "alarm", + "battery", + "power", + "nuclear", + "rocket", + "temperature", + "finish", + "gears", + "star", + "light", + "mine", + "oil", + "gun", + "tank", + "train", + "wall", + "siren", + "warning-shield", + "warning-triangle" + } + } } -- Create new virtual signals with icons for i, iconset in pairs(iconsets) do - data:extend({ + data:extend( { - type = "item-subgroup", - name = iconset.name, - group = "signals", - order = iconset.order + { + type = "item-subgroup", + name = iconset.name, + group = "signals", + order = iconset.order + } } - }) + ) local pos = 1 for j, icon in pairs(iconset.icons) do - - data:extend({ + data:extend( { - type = "virtual-signal", - name = "dect-signal-"..iconset.name.."-"..icon, - localised_name = { "dect-signal."..iconset.name.."-"..icon }, - icons = { - { icon = "__base__/graphics/icons/signal/signal_grey.png", tint = iconset.background }, - { icon = "__Dectorio__/graphics/signal/"..iconset.name.."-"..icon..".png" } - }, - icon_size = 32, - subgroup = iconset.name, - order = iconset.order.."["..iconset.name.."]-"..char(pos).."["..icon.."]" + { + type = "virtual-signal", + name = "dect-signal-" .. iconset.name .. "-" .. icon, + localised_name = {"dect-signal." .. iconset.name .. "-" .. icon}, + icons = { + { + icon = "__base__/graphics/icons/signal/signal_grey.png", + tint = iconset.background, + icon_size = 64, + icon_mipmaps = 4 + }, + { + icon = "__Dectorio__/graphics/signal/" .. iconset.name .. "-" .. icon .. ".png", + icon_size = 32, + icon_mipmaps = 1 + } + }, + subgroup = iconset.name, + order = iconset.order .. "[" .. iconset.name .. "]-" .. char(pos) .. "[" .. icon .. "]" + } } - }) + ) pos = pos + 1 end end - end diff --git a/prototypes/third-party/alien-biomes.lua b/prototypes/third-party/alien-biomes.lua index 591dbaf..5f941d0 100644 --- a/prototypes/third-party/alien-biomes.lua +++ b/prototypes/third-party/alien-biomes.lua @@ -135,7 +135,8 @@ if DECT.ENABLED["landscaping"] and mods["alien-biomes"] then type = "item", name = "dect-alien-biomes-"..tree, icon = data.raw["tree"][tree].icon, - icon_size = 32, + icon_size = 64, + icon_mipmaps = 4, subgroup = "landscaping-trees", order = "a[alien-biomes-"..tree.."]", stack_size = DECT.CONFIG.SETTINGS["landscaping_stack_size"], @@ -166,7 +167,8 @@ if DECT.ENABLED["landscaping"] and mods["alien-biomes"] then icons = { { icon = data.raw["simple-entity"][rock.name].icon, tint = rock.color } }, - icon_size = 32, + icon_size = 64, + icon_mipmaps = 4, subgroup = "landscaping-rocks", order = "a[alien-biomes-"..rock.name.."]", stack_size = DECT.CONFIG.SETTINGS["landscaping_stack_size"],