diff --git a/Baseless.lua b/Baseless.lua deleted file mode 100644 index 6172335..0000000 --- a/Baseless.lua +++ /dev/null @@ -1,274 +0,0 @@ -Baseless = {} -Baseless.Needs = {} - - --- FIXME -Baseless.RenderLayer = "water-tile" - -Baseless.Image = "__core__/graphics/empty.png" -Baseless.Image32 = "__core__/graphics/factorio-icon.png" -Baseless.Sound = -{ - filename = "__core__/sound/achievement-unlocked.ogg", -} - -Baseless.RotatedAnimation = -{ - filename = Baseless.Image, - size = 1, - direction_count = 18, -} -Baseless.RotatedAnimation32 = -{ - filename = Baseless.Image32, - size = 1, - direction_count = 18, -} -Baseless.RotatedAnimation4Way = Baseless.RotatedAnimation -Baseless.RotatedAnimation4Way32 = Baseless.RotatedAnimation32 --- END - - - -Baseless._AmmoType = {category = "dummy-ammo-category"} -Baseless.AmmoType = function (register) - if register then - Baseless.Needs.AmmoType = true - end - return Baseless._AmmoType -end - -Baseless.AttackParameters = {} -Baseless.AttackParameters._Stream = -{ - type = "stream", - range = 0, - cooldown = 0, - ammo_type = Baseless._AmmoType, - animation = Baseless.RotatedAnimation32, -} -Baseless.AttackParameters.Stream = function (register) - if register then - Baseless.AmmoType(true) - end - return Baseless.AttackParameters._Stream -end - - -Baseless._DamagePrototype = -{ - amount = 1, - type = "dummy-damage-type", -} -Baseless.DamagePrototype = function (register) - if register then - Baseless.Needs.DamageType = true - end - return Baseless._DamagePrototype -end - - -Baseless.EnergySource = {} -Baseless.EnergySource._Burner = -{ - type = "burner", - fuel_inventory_size = 0, - fuel_category = "dummy-fuel-category", -} -Baseless.EnergySource.Burner = function (register) - if register then - Baseless.Needs.FuelType = true - end - return Baseless.EnergySource._Burner -end - -Baseless.EnergySource.Electric = -{ - type = "electric", - usage_priority = "tertiary", -} - -Baseless.EnergySource.Void = -{ - type = "void", - usage_priority = "tertiary", -} - - -Baseless._ModuleType = "dummy-module-category" -Baseless.ModuleType = function (register) - if register then - Baseless.Needs.ModuleType = true - end - return Baseless._ModuleType -end - - -Baseless._RecipeType = "dummy-recipe-category" -Baseless.RecipeType = function (register) - if register then - Baseless.Needs.RecipeType = true - end - return Baseless._RecipeType -end - - -Baseless._ResourceType = "dummy-resource-category" -Baseless.ResourceType = function (register) - if register then - Baseless.Needs.ResourceType = true - end - return Baseless._ResourceType -end - - -Baseless._ScienceType = "dummy-science-pack" -Baseless.ScienceType = function (register) - if register then - Baseless.Needs.ScienceType = true - end - return Baseless._ScienceType -end - - - --- FIXME - -Baseless.IconSpecification = -{ - icon = Baseless.Image, - icon_size = 1, -} - -Baseless.BoundingBox = {{0, 0}, {0, 0}} - -Baseless.Color = {0, 0, 0} - -Baseless.Sprite = -{ - filename = Baseless.Image32, - size = 1, -} -Baseless.RotatedSprite = -{ - filename = Baseless.Image, - size = 1, - direction_count = 1, -} - -Baseless.SpriteVariations = -{ - sheet = Baseless.Sprite, -} - -Baseless.Animation = -{ - filename = Baseless.Image32, - size = 1, - variation_count = 12, -} -Baseless.Animation4Way = Baseless.Animation -Baseless.AnimationVariations = -{ - sheet = Baseless.Animation, -} - -Baseless.RotatedAnimation = -{ - filename = Baseless.Image32, - size = 1, - direction_count = 18, -} -Baseless.RotatedAnimation4Way = Baseless.RotatedAnimation - -Baseless.Sprite4Way = Baseless.Sprite -Baseless.Sprite8Way = -{ - sheets = {Baseless.Sprite}, -} - -Baseless.CombinatorOffsets = -{ - {0, 0}, - {0, 0}, - {0, 0}, - {0, 0}, -} - -Baseless.WireConnectionPoint = {} -Baseless.WireConnectionPoint.Combinator = -{ - {wire = {}, shadow = {}}, - {wire = {}, shadow = {}}, - {wire = {}, shadow = {}}, - {wire = {}, shadow = {}}, -} -Baseless.WireConnectionPoint.Pole = -{ - {wire = {}, shadow = {}}, -} -Baseless.WireConnectionPoint.PowerSwitch = {wire = {}, shadow = {}} - -Baseless.FluidBox = {pipe_connections = {}} - -Baseless.HeatBuffer = -{ - max_temperature = 15, - specific_heat = "1W", - max_transfer = "1W", -} - -Baseless.TransportBeltConnectorFrame = -{ - frame_main = Baseless.AnimationVariations, - frame_shadow = Baseless.AnimationVariations, - frame_main_scanner = Baseless.Animation, - frame_main_scanner_movement_speed = 1, - frame_main_scanner_horizontal_start_shift = {0, 0}, - frame_main_scanner_horizontal_end_shift = {0, 0}, - frame_main_scanner_horizontal_y_scale = 1, - frame_main_scanner_horizontal_rotation = 0, - frame_main_scanner_vertical_start_shift = {0, 0}, - frame_main_scanner_vertical_end_shift = {0, 0}, - frame_main_scanner_vertical_y_scale = 1, - frame_main_scanner_vertical_rotation = 0, - frame_main_scanner_cross_horizontal_start_shift = {0, 0}, - frame_main_scanner_cross_horizontal_end_shift = {0, 0}, - frame_main_scanner_cross_horizontal_y_scale = 1, - frame_main_scanner_cross_horizontal_rotation = 0, - frame_main_scanner_cross_vertical_start_shift = {0, 0}, - frame_main_scanner_cross_vertical_end_shift = {0, 0}, - frame_main_scanner_cross_vertical_y_scale = 1, - frame_main_scanner_cross_vertical_rotation = 0, - frame_main_scanner_nw_ne = Baseless.Animation, - frame_main_scanner_sw_se = Baseless.Animation, -} - -Baseless.BeltAnimation = -{ - filename = Baseless.Image32, - size = 1, - variation_count = 1, - direction_count = 12, -} - -Baseless.EquipmentShape = -{ - width = 1, - height = 1, - type = "full", -} - -Baseless.TileTransitionSprite = -{ - count = 1, - picture = Baseless.Image32, - size = 1, -} -Baseless.Transitions = -{ - main = {Baseless.TileTransitionSprite}, - empty_transitions = true, -} - --- END diff --git a/Baseless/Baseless.lua b/Baseless/Baseless.lua new file mode 100644 index 0000000..e2eef74 --- /dev/null +++ b/Baseless/Baseless.lua @@ -0,0 +1,11 @@ +Baseless = {} +Baseless.PrototypeCount = 0 + +require("Data") +require("Graphics") +require("Register") +require("Sound") + +Baseless.Make = {} +Baseless.Needs = {} +require("prototypes.constructors") diff --git a/Baseless/Data.lua b/Baseless/Data.lua new file mode 100644 index 0000000..517d4f2 --- /dev/null +++ b/Baseless/Data.lua @@ -0,0 +1,78 @@ +Baseless.Data = {} + +Baseless.Data.BoundingBox = {{-1, -1}, {1, 1}} +Baseless.Data.CollisionMask = {} +Baseless.Data.Color = {} +Baseless.Data.DaytimeColorLookupTable = {{1, "identity"}} +Baseless.Data.Effect = {} +Baseless.Data.Energy = "1W" +Baseless.Data.FluidBox = {pipe_connections = {}} +Baseless.Data.ModuleSpecification = {} +Baseless.Data.SelectionType = "not-allowed" +Baseless.Data.SelectionMode = {"nothing"} +Baseless.Data.SpeechBubbleStyle = "compilatron_speech_bubble" + +Baseless.Data.AmmoType = {category = "dummy-ammo-category"} +Baseless.Data.EquipmentType = "dummy-equipment-category" +Baseless.Data.FuelType = "dummy-fuel-category" +Baseless.Data.ModuleType = "dummy-module-category" +Baseless.Data.RecipeType = "dummy-recipe-category" +Baseless.Data.ResourceType = "dummy-resource-category" +Baseless.Data.Fluid = "dummy-fluid" +Baseless.Data.Group = "other" +Baseless.Data.CurvedRailEntity = "dummy-curved-rail" +Baseless.Data.RocketEntity = "dummy-rocket-silo-rocket" +Baseless.Data.StraightRailEntity = "dummy-straight-rail" +Baseless.Data.UnitEntity = "dummy-unit" +Baseless.Data.GunItem = "dummy-gun" +Baseless.Data.Particle = "dummy-optimized-particle" + +Baseless.Data.AttackParameters = +{ + type = "stream", -- StreamAttackParameters + range = 0, + cooldown = 0, + ammo_type = Baseless.Data.AmmoType, +} + +Baseless.Data.DamagePrototype = +{ + amount = 0, + type = "physical", +} + +Baseless.Data.EnergySource = {} +Baseless.Data.EnergySource.Burner = +{ + type = "burner", + fuel_inventory_size = 0, + fuel_category = Baseless.Data.FuelType, +} +Baseless.Data.EnergySource.Electric = +{ + type = "electric", + usage_priority = "tertiary", +} + +Baseless.Data.EquipmentShape = +{ + width = 1, + height = 1, + type = "full", +} + +Baseless.Data.HeatBuffer = +{ + max_temperature = 15, + specific_heat = Baseless.Data.Energy, + max_transfer = Baseless.Data.Energy, +} + +Baseless.Data.MinableProperties = +{ + mining_time = 1, +} + +Baseless.Data.Vector = {} +Baseless.Data.Vector.Zero = {0, 0} +Baseless.Data.Vector.One = {1, 1} diff --git a/Baseless/Graphics.lua b/Baseless/Graphics.lua new file mode 100644 index 0000000..8ca1477 --- /dev/null +++ b/Baseless/Graphics.lua @@ -0,0 +1,117 @@ +Baseless.Graphics = {} + +Baseless.Graphics.Image1 = "__core__/graphics/empty.png" +Baseless.Graphics.Image32 = "__core__/graphics/too-far.png" + +Baseless.Graphics.IconSpecification = +{ + icon = Baseless.Graphics.Image1, + icon_size = 1, +} + +Baseless.Graphics.Animation = +{ + filename = Baseless.Graphics.Image1, + size = 1, +} +Baseless.Graphics.Animation4Way = Baseless.Graphics.Animation +Baseless.Graphics.AnimationVariations = +{ + sheet = Merge( + Baseless.Graphics.Animation, + { + variation_count = 1, + } + ), +} +Baseless.Graphics.RotatedAnimation = +{ + filename = Baseless.Graphics.Image1, + size = 1, + direction_count = 1, +} +Baseless.Graphics.RotatedAnimation4Way = Baseless.Graphics.RotatedAnimation + +Baseless.Graphics.Animation32 = +{ + filename = Baseless.Graphics.Image32, + size = 1, +} +Baseless.Graphics.RotatedAnimation32 = +{ + filename = Baseless.Graphics.Image32, + size = 1, + direction_count = 1, +} + +Baseless.Graphics.Sprite = +{ + filename = Baseless.Graphics.Image1, + size = 1, +} +Baseless.Graphics.Sprite4Way = Baseless.Graphics.Sprite +Baseless.Graphics.SpriteVariations = +{ + sheet = Baseless.Graphics.Sprite, +} +Baseless.Graphics.RotatedSprite = +{ + filename = Baseless.Graphics.Image1, + size = 1, + direction_count = 1, +} + +Baseless.Graphics.Sprite32 = +{ + filename = Baseless.Graphics.Image32, + size = 1, +} +Baseless.Graphics.SpriteVariations32 = +{ + sheet = Baseless.Graphics.Sprite32, +} +Baseless.Graphics.Sprite8Way32 = +{ + sheets = {Baseless.Graphics.Sprite32}, +} + +Baseless.Graphics.TileTransitionSprite = +{ + count = 1, + picture = Baseless.Graphics.Image32, + size = 1, +} +Baseless.Graphics.Transitions = +{ + main = + { + Baseless.Graphics.TileTransitionSprite, + }, + empty_transitions = true, +} + +Baseless.Graphics.RailPieceLayers = +{ + metals = Baseless.Graphics.SpriteVariations32, + backplates = Baseless.Graphics.SpriteVariations32, + ties = Baseless.Graphics.SpriteVariations32, + stone_path = Baseless.Graphics.SpriteVariations32, +} +Baseless.Graphics.RailPictures = +{ + straight_rail_horizontal = Baseless.Graphics.RailPieceLayers, + straight_rail_vertical = Baseless.Graphics.RailPieceLayers, + straight_rail_diagonal_left_top = Baseless.Graphics.RailPieceLayers, + straight_rail_diagonal_right_top = Baseless.Graphics.RailPieceLayers, + straight_rail_diagonal_right_bottom = Baseless.Graphics.RailPieceLayers, + straight_rail_diagonal_left_bottom = Baseless.Graphics.RailPieceLayers, + curved_rail_vertical_left_top = Baseless.Graphics.RailPieceLayers, + curved_rail_vertical_right_top = Baseless.Graphics.RailPieceLayers, + curved_rail_vertical_right_bottom = Baseless.Graphics.RailPieceLayers, + curved_rail_vertical_left_bottom = Baseless.Graphics.RailPieceLayers, + curved_rail_horizontal_left_top = Baseless.Graphics.RailPieceLayers, + curved_rail_horizontal_right_top = Baseless.Graphics.RailPieceLayers, + curved_rail_horizontal_right_bottom = Baseless.Graphics.RailPieceLayers, + curved_rail_horizontal_left_bottom = Baseless.Graphics.RailPieceLayers, + rail_endings = Baseless.Graphics.Sprite8Way32, +} diff --git a/Baseless/Register.lua b/Baseless/Register.lua new file mode 100644 index 0000000..ca4a592 --- /dev/null +++ b/Baseless/Register.lua @@ -0,0 +1,57 @@ +Baseless._RegisterIfNew = function (prototype) + local type = prototype.type + local name = prototype.name + if data.raw[type] == nil or data.raw[type][name] == nil then + Baseless.PrototypeCount = Baseless.PrototypeCount + 1 + log(" ✓ [" .. type .. "]" .. name .. " - IfNew") + data:extend { prototype } + Baseless.EnableConditions(prototype.baseless_conditions or {}) + return true + else + log("✗ [" .. type .. "]" .. name .. " - IfNew") + return false + end +end +Baseless.RegisterIfNew = function (prototypes) + if #prototypes == 0 then + return Baseless._RegisterIfNew(prototypes) + end + for _, prototype in ipairs(prototypes) do + Baseless._RegisterIfNew(prototype) + end +end + +Baseless._RegisterIfUnique = function (prototype) + local type = prototype.type + local name = prototype.name + if data.raw[type] == nil then + Baseless.PrototypeCount = Baseless.PrototypeCount + 1 + log("✓ [" .. type .. "]" .. name .. " - IfUnique") + data:extend { prototype } + Baseless.EnableConditions(prototype.baseless_conditions or {}) + return true + else + log("✗ [" .. type .. "]" .. name .. " - IfUnique") + return false + end +end +Baseless.RegisterIfUnique = function (prototypes) + if #prototypes == 0 then + return Baseless._RegisterIfUnique(prototypes) + end + for _, prototype in ipairs(prototypes) do + Baseless._RegisterIfUnique(prototype) + end +end + +Baseless.EnableCondition = function (condition) + if Baseless.Needs[condition] ~= true then + Baseless.Needs[condition] = true + log(" - Condition: " .. condition .. " - Enabled") + end +end +Baseless.EnableConditions = function (conditions) + for _, condition in ipairs(conditions) do + Baseless.EnableCondition(condition) + end +end diff --git a/Baseless/Sound.lua b/Baseless/Sound.lua new file mode 100644 index 0000000..7d88204 --- /dev/null +++ b/Baseless/Sound.lua @@ -0,0 +1,4 @@ +Baseless.Sound = +{ + filename = "__core__/sound/achievement-unlocked.ogg", +} diff --git a/Helpers/Append.lua b/Helpers/Append.lua new file mode 100644 index 0000000..690825a --- /dev/null +++ b/Helpers/Append.lua @@ -0,0 +1,14 @@ +-- Append multiple tables together +-- +-- *Values are not deep copies +function Append(...) + local newArray = {} + for _, array in ipairs({...}) do + if array then + for _, value in ipairs(array) do + table.insert(newArray, value) + end + end + end + return newArray +end diff --git a/Helpers/Merge.lua b/Helpers/Merge.lua new file mode 100644 index 0000000..dfea761 --- /dev/null +++ b/Helpers/Merge.lua @@ -0,0 +1,15 @@ +-- Combine multiple tables into one +-- +-- *In the case of duplicate keys the latest one is used +-- *Values are not deep copies +function Merge(...) + local newTable = {} + for _, table in ipairs({...}) do + if table then + for key, value in pairs(table) do + newTable[key] = value + end + end + end + return newTable +end diff --git a/README.md b/README.md index eb3e7d3..9c6fa47 100644 --- a/README.md +++ b/README.md @@ -2,4 +2,10 @@ Defines missing prototypes required to launch the game. -**Incompatible with the base mod.** +--- + +## Folder structure + +- `Baseless` - shared constants +- `Helpers` - generic functions +- `prototypes/constructors` mirrors [https://wiki.factorio.com/Prototype_definitions](https://wiki.factorio.com/Prototype_definitions) diff --git a/changelog.txt b/changelog.txt new file mode 100644 index 0000000..e1b57a1 --- /dev/null +++ b/changelog.txt @@ -0,0 +1,5 @@ +--------------------------------------------------------------------------------------------------- +Version: 0.0.1 +Date: 26.04.2020 + Features: + - Initial release diff --git a/data-final-fixes.lua b/data-final-fixes.lua index f861186..d6cee00 100644 --- a/data-final-fixes.lua +++ b/data-final-fixes.lua @@ -1,198 +1,9 @@ -require("Baseless") +require("prototypes.required") -require("helpers.MergeTables") +require("prototypes.entity") +require("prototypes.equipment") +require("prototypes.item") --- Prototype Hierarchy -require("helpers.CreatePrototype") - require("helpers.CreateItem") - require("helpers.CreateItemWithLabel") - require("helpers.CreateItemWithInventory") - require("helpers.CreateItemWithTags") - require("helpers.CreateSelectionTool") - require("helpers.CreateTool") - require("helpers.CreateEntity") - require("helpers.CreateCorpse") - require("helpers.CreateEntityWithHealth") - require("helpers.CreateCombinator") - require("helpers.CreateContainer") - require("helpers.CreateLogisticContainer") - require("helpers.CreateCraftingMachine") - require("helpers.CreateAssemblingMachine") - require("helpers.CreateFlyingRobot") - require("helpers.CreateRobotWithLogisticInterface") - require("helpers.CreatePipe") - require("helpers.CreateRail") - require("helpers.CreateRailSignalBase") - require("helpers.CreateTransportBeltConnectable") - require("helpers.CreateTurret") - require("helpers.CreateVehicle") - require("helpers.CreateRollingStock") - require("helpers.CreateExplosion") - require("helpers.CreateSmoke") - require("helpers.CreateEquipment") +require("prototypes.conditional") --- Items -require("prototypes.item.ammo") -require("prototypes.item.armor") -require("prototypes.item.blueprint") -require("prototypes.item.blueprint-book") -require("prototypes.item.capsule") -require("prototypes.item.copy-paste-tool") -require("prototypes.item.deconstruction-item") -require("prototypes.item.gun") -require("prototypes.item.item") -require("prototypes.item.item-with-entity-data") -require("prototypes.item.item-with-inventory") -require("prototypes.item.item-with-label") -require("prototypes.item.item-with-tags") -require("prototypes.item.mining-tool") -require("prototypes.item.module") -require("prototypes.item.rail-planner") -require("prototypes.item.repair-tool") -require("prototypes.item.selection-tool") -require("prototypes.item.tool") -require("prototypes.item.upgrade-item") - --- Entities (depends on above) - - --- Entities -require("prototypes.entity.accumulator") -require("prototypes.entity.ammo-turret") -require("prototypes.entity.arithmetic-combinator") -require("prototypes.entity.arrow") -require("prototypes.entity.artillery-flare") -require("prototypes.entity.artillery-projectile") -require("prototypes.entity.artillery-turret") -require("prototypes.entity.artillery-wagon") -require("prototypes.entity.assembling-machine") -require("prototypes.entity.beacon") -require("prototypes.entity.beam") -require("prototypes.entity.boiler") -require("prototypes.entity.burner-generator") -require("prototypes.entity.car") -require("prototypes.entity.cargo-wagon") -require("prototypes.entity.character") -require("prototypes.entity.character-corpse") -require("prototypes.entity.cliff") -require("prototypes.entity.combat-robot") -require("prototypes.entity.constant-combinator") -require("prototypes.entity.construction-robot") -require("prototypes.entity.container") -require("prototypes.entity.corpse") -require("prototypes.entity.decider-combinator") -require("prototypes.entity.deconstructible-tile-proxy") -require("prototypes.entity.decorative") -require("prototypes.entity.electric-energy-interface") -require("prototypes.entity.electric-pole") -require("prototypes.entity.electric-turret") -require("prototypes.entity.entity-ghost") -require("prototypes.entity.explosion") -require("prototypes.entity.fire") -require("prototypes.entity.fish") -require("prototypes.entity.flame-thrower-explosion") -require("prototypes.entity.fluid-turret") -require("prototypes.entity.fluid-wagon") -require("prototypes.entity.flying-text") -require("prototypes.entity.furnace") -require("prototypes.entity.gate") -require("prototypes.entity.generator") -require("prototypes.entity.heat-interface") -require("prototypes.entity.heat-pipe") -require("prototypes.entity.highlight-box") -require("prototypes.entity.infinity-container") -require("prototypes.entity.infinity-pipe") -require("prototypes.entity.inserter") -require("prototypes.entity.item-entity") -require("prototypes.entity.item-request-proxy") -require("prototypes.entity.lab") -require("prototypes.entity.lamp") -require("prototypes.entity.land-mine") -require("prototypes.entity.leaf-particle") -require("prototypes.entity.loader") -require("prototypes.entity.loader-1x1") -require("prototypes.entity.locomotive") -require("prototypes.entity.logistic-container") -require("prototypes.entity.logistic-robot") -require("prototypes.entity.market") -require("prototypes.entity.mining-drill") -require("prototypes.entity.offshore-pump") -require("prototypes.entity.particle") -require("prototypes.entity.particle-source") -require("prototypes.entity.pipe") -require("prototypes.entity.pipe-to-ground") -require("prototypes.entity.player-port") -require("prototypes.entity.power-switch") -require("prototypes.entity.programmable-speaker") -require("prototypes.entity.projectile") -require("prototypes.entity.pump") -require("prototypes.entity.radar") -require("prototypes.entity.rail-chain-signal") -require("prototypes.entity.rail-remnants") -require("prototypes.entity.rail-signal") -require("prototypes.entity.reactor") -require("prototypes.entity.resource") -require("prototypes.entity.roboport") -require("prototypes.entity.rocket-silo") -require("prototypes.entity.rocket-silo-rocket-shadow") -require("prototypes.entity.simple-entity") -require("prototypes.entity.simple-entity-with-force") -require("prototypes.entity.simple-entity-with-owner") -require("prototypes.entity.smoke") -require("prototypes.entity.smoke-with-trigger") -require("prototypes.entity.solar-panel") -require("prototypes.entity.speech-bubble") -require("prototypes.entity.splitter") -require("prototypes.entity.sticker") -require("prototypes.entity.storage-tank") -require("prototypes.entity.stream") -require("prototypes.entity.tile-ghost") -require("prototypes.entity.train-stop") -require("prototypes.entity.transport-belt") -require("prototypes.entity.tree") -require("prototypes.entity.turret") -require("prototypes.entity.underground-belt") -require("prototypes.entity.unit-spawner") -require("prototypes.entity.wall") - --- Equipment -require("prototypes.equipment.active-defense-equipment") -require("prototypes.equipment.battery-equipment") -require("prototypes.equipment.belt-immunity-equipment") -require("prototypes.equipment.energy-shield-equipment") -require("prototypes.equipment.generator-equipment") -require("prototypes.equipment.movement-bonus-equipment") -require("prototypes.equipment.night-vision-equipment") -require("prototypes.equipment.roboport-equipment") -require("prototypes.equipment.solar-panel-equipment") - --- Items (depends on above) -require("prototypes.item.science") - --- Entities (depends on above) -require("prototypes.entity.curved-rail") -require("prototypes.entity.rocket-silo-rocket") -require("prototypes.entity.straight-rail") -require("prototypes.entity.unit") - --- Categories (depends on above) -require("prototypes.category.ammo") -require("prototypes.category.damage") -require("prototypes.category.equipment") -require("prototypes.category.fuel") -require("prototypes.category.module") -require("prototypes.category.recipe") -require("prototypes.category.resource") -require("prototypes.category.trigger-target") - --- Other (depends on above) -require("prototypes.item-group") -require("prototypes.item.copper-cable") -require("prototypes.item.green-wire") -require("prototypes.item.red-wire") -require("prototypes.other.equipment-grid") -require("prototypes.other.fluid") -require("prototypes.other.optimized-particle") -require("prototypes.other.tile") -require("prototypes.other.trivial-smoke") -require("prototypes.other.virtual-signal") +log("Added " .. Baseless.PrototypeCount .. " prototypes") diff --git a/data.lua b/data.lua index afa5623..837de42 100644 --- a/data.lua +++ b/data.lua @@ -1 +1,5 @@ +require("Helpers.Append") +require("Helpers.Merge") + +require("Baseless.Baseless") require("prototypes.map-settings") diff --git a/helpers/CreateAssemblingMachine.lua b/helpers/CreateAssemblingMachine.lua deleted file mode 100644 index 38f1296..0000000 --- a/helpers/CreateAssemblingMachine.lua +++ /dev/null @@ -1,3 +0,0 @@ -function CreateAssemblingMachine (type, prototype) - return CreateCraftingMachine(type, prototype) -end diff --git a/helpers/CreateCombinator.lua b/helpers/CreateCombinator.lua deleted file mode 100644 index 74a4d90..0000000 --- a/helpers/CreateCombinator.lua +++ /dev/null @@ -1,20 +0,0 @@ -function CreateCombinator (type, prototype) - return CreateEntityWithHealth( - type, - MergeTables( - prototype, - { - active_energy_usage = "1W", - activity_led_light_offsets = Baseless.CombinatorOffsets, - activity_led_sprites = Baseless.Sprite4Way, - energy_source = Baseless.EnergySource.Void, - input_connection_bounding_box = Baseless.BoundingBox, - input_connection_points = Baseless.WireConnectionPoint.Combinator, - output_connection_bounding_box = Baseless.BoundingBox, - output_connection_points = Baseless.WireConnectionPoint.Combinator, - screen_light_offsets = Baseless.CombinatorOffsets, - sprites = Baseless.Sprite4Way, - } - ) - ) -end diff --git a/helpers/CreateContainer.lua b/helpers/CreateContainer.lua deleted file mode 100644 index e3bf6d2..0000000 --- a/helpers/CreateContainer.lua +++ /dev/null @@ -1,12 +0,0 @@ -function CreateContainer (type, prototype) - return CreateEntityWithHealth( - type, - MergeTables( - prototype, - { - inventory_size = 1, - picture = Baseless.Sprite, - } - ) - ) -end diff --git a/helpers/CreateCorpse.lua b/helpers/CreateCorpse.lua deleted file mode 100644 index 592cdc0..0000000 --- a/helpers/CreateCorpse.lua +++ /dev/null @@ -1,3 +0,0 @@ -function CreateCorpse (type, prototype) - return CreateEntity(type, prototype) -end diff --git a/helpers/CreateCraftingMachine.lua b/helpers/CreateCraftingMachine.lua deleted file mode 100644 index 819a0e4..0000000 --- a/helpers/CreateCraftingMachine.lua +++ /dev/null @@ -1,18 +0,0 @@ -function CreateCraftingMachine (type, prototype) - if CreateEntityWithHealth( - type, - MergeTables( - prototype, - { - crafting_categories = {Baseless.RecipeType()}, - crafting_speed = 1, - energy_source = Baseless.EnergySource.Void, - energy_usage = "1W", - } - ) - ) then - Baseless.RecipeType(true) - return true - end - return false -end diff --git a/helpers/CreateEntity.lua b/helpers/CreateEntity.lua deleted file mode 100644 index 5539d3a..0000000 --- a/helpers/CreateEntity.lua +++ /dev/null @@ -1,16 +0,0 @@ -function CreateEntity (type, prototype) - if CreateUniquePrototype( - type, - MergeTables( - prototype, - Baseless.IconSpecification, - { - subgroup = "dummy-item-subgroup", - } - ) - ) then - Baseless.Needs.ItemGroup = true - return true - end - return false -end diff --git a/helpers/CreateEntityWithHealth.lua b/helpers/CreateEntityWithHealth.lua deleted file mode 100644 index 47dd83e..0000000 --- a/helpers/CreateEntityWithHealth.lua +++ /dev/null @@ -1,3 +0,0 @@ -function CreateEntityWithHealth (type, prototype) - return CreateEntity(type, prototype) -end diff --git a/helpers/CreateEquipment.lua b/helpers/CreateEquipment.lua deleted file mode 100644 index 7a465c2..0000000 --- a/helpers/CreateEquipment.lua +++ /dev/null @@ -1,30 +0,0 @@ -function CreateEquipment (type, prototype) - if CreateUniquePrototype( - type, - MergeTables( - prototype, - Baseless.IconSpecification, - { - categories = {"dummy-equipment-category"}, - energy_source = Baseless.EnergySource.Void, - shape = Baseless.EquipmentShape, - sprite = Baseless.Sprite, - } - ) - ) then - Baseless.Needs.EquipmentType = true - data:extend - { - { - type = "item", - name = "dummy-" .. type, - icon = Baseless.Image, - icon_size = 1, - stack_size = 1, - subgroup = "dummy-item-subgroup", - }, - } - return true - end - return false -end diff --git a/helpers/CreateExplosion.lua b/helpers/CreateExplosion.lua deleted file mode 100644 index cffa3bc..0000000 --- a/helpers/CreateExplosion.lua +++ /dev/null @@ -1,11 +0,0 @@ -function CreateExplosion (type, prototype) - return CreateEntity( - type, - MergeTables( - prototype, - { - animations = Baseless.AnimationVariations, - } - ) - ) -end diff --git a/helpers/CreateFlyingRobot.lua b/helpers/CreateFlyingRobot.lua deleted file mode 100644 index 33486c2..0000000 --- a/helpers/CreateFlyingRobot.lua +++ /dev/null @@ -1,11 +0,0 @@ -function CreateFlyingRobot (type, prototype) - return CreateEntityWithHealth( - type, - MergeTables( - prototype, - { - speed = 1, - } - ) - ) -end diff --git a/helpers/CreateItem.lua b/helpers/CreateItem.lua deleted file mode 100644 index c6b98ac..0000000 --- a/helpers/CreateItem.lua +++ /dev/null @@ -1,17 +0,0 @@ -function CreateItem (type, prototype) - if CreateUniquePrototype( - type, - MergeTables( - prototype, - Baseless.IconSpecification, - { - stack_size = 1, - subgroup = "dummy-item-subgroup", - } - ) - ) then - Baseless.Needs.ItemGroup = true - return true - end - return false -end diff --git a/helpers/CreateItemWithInventory.lua b/helpers/CreateItemWithInventory.lua deleted file mode 100644 index 199905b..0000000 --- a/helpers/CreateItemWithInventory.lua +++ /dev/null @@ -1,11 +0,0 @@ -function CreateItemWithInventory (type, prototype) - return CreateItemWithLabel( - type, - MergeTables( - prototype, - { - inventory_size = 0, - } - ) - ) -end diff --git a/helpers/CreateItemWithLabel.lua b/helpers/CreateItemWithLabel.lua deleted file mode 100644 index 70ef3e3..0000000 --- a/helpers/CreateItemWithLabel.lua +++ /dev/null @@ -1,3 +0,0 @@ -function CreateItemWithLabel (type, prototype) - return CreateItem(type, prototype) -end diff --git a/helpers/CreateItemWithTags.lua b/helpers/CreateItemWithTags.lua deleted file mode 100644 index f80927b..0000000 --- a/helpers/CreateItemWithTags.lua +++ /dev/null @@ -1,3 +0,0 @@ -function CreateItemWithTags (type, prototype) - return CreateItemWithLabel(type, prototype) -end diff --git a/helpers/CreateLogisticContainer.lua b/helpers/CreateLogisticContainer.lua deleted file mode 100644 index ebc3646..0000000 --- a/helpers/CreateLogisticContainer.lua +++ /dev/null @@ -1,11 +0,0 @@ -function CreateLogisticContainer (type, prototype) - return CreateContainer( - type, - MergeTables( - prototype, - { - logistic_mode = "storage", - } - ) - ) -end diff --git a/helpers/CreatePipe.lua b/helpers/CreatePipe.lua deleted file mode 100644 index 28f79e9..0000000 --- a/helpers/CreatePipe.lua +++ /dev/null @@ -1,43 +0,0 @@ -Baseless.PipePictures = -{ - straight_vertical_single = Baseless.Sprite, - straight_vertical = Baseless.Sprite, - straight_vertical_window = Baseless.Sprite, - straight_horizontal = Baseless.Sprite, - straight_horizontal_window = Baseless.Sprite, - corner_up_right = Baseless.Sprite, - corner_up_left = Baseless.Sprite, - corner_down_right = Baseless.Sprite, - corner_down_left = Baseless.Sprite, - t_up = Baseless.Sprite, - t_down = Baseless.Sprite, - t_right = Baseless.Sprite, - t_left = Baseless.Sprite, - cross = Baseless.Sprite, - ending_up = Baseless.Sprite, - ending_down = Baseless.Sprite, - ending_right = Baseless.Sprite, - ending_left = Baseless.Sprite, - horizontal_window_background = Baseless.Sprite, - vertical_window_background = Baseless.Sprite, - fluid_background = Baseless.Sprite, - low_temperature_flow = Baseless.Sprite, - middle_temperature_flow = Baseless.Sprite, - high_temperature_flow = Baseless.Sprite, - gas_flow = Baseless.Animation, -} - -function CreatePipe (type, prototype) - return CreateEntityWithHealth( - type, - MergeTables( - prototype, - { - fluid_box = Baseless.FluidBox, - horizontal_window_bounding_box = Baseless.BoundingBox, - pictures = Baseless.PipePictures, - vertical_window_bounding_box = Baseless.BoundingBox, - } - ) - ) -end diff --git a/helpers/CreatePrototype.lua b/helpers/CreatePrototype.lua deleted file mode 100644 index a7b775b..0000000 --- a/helpers/CreatePrototype.lua +++ /dev/null @@ -1,22 +0,0 @@ -function CreatePrototype (type, prototype) - data:extend - { - MergeTables( - prototype, - { - type = type, - name = "dummy-" .. type, - flags = {"hidden"}, -- Make everything hidden - } - ), - } -end - --- Does not create if that type already exists -function CreateUniquePrototype (type, prototype) - if data.raw[type] == nil then - CreatePrototype(type, prototype) - return true - end - return false -end diff --git a/helpers/CreateRail.lua b/helpers/CreateRail.lua deleted file mode 100644 index a217660..0000000 --- a/helpers/CreateRail.lua +++ /dev/null @@ -1,38 +0,0 @@ -Baseless.RailPieceLayers = -{ - metals = Baseless.SpriteVariations, - backplates = Baseless.SpriteVariations, - ties = Baseless.SpriteVariations, - stone_path = Baseless.SpriteVariations, -} - -Baseless.RailPictures = -{ - straight_rail_horizontal = Baseless.RailPieceLayers, - straight_rail_vertical = Baseless.RailPieceLayers, - straight_rail_diagonal_left_top = Baseless.RailPieceLayers, - straight_rail_diagonal_right_top = Baseless.RailPieceLayers, - straight_rail_diagonal_right_bottom = Baseless.RailPieceLayers, - straight_rail_diagonal_left_bottom = Baseless.RailPieceLayers, - curved_rail_vertical_left_top = Baseless.RailPieceLayers, - curved_rail_vertical_right_top = Baseless.RailPieceLayers, - curved_rail_vertical_right_bottom = Baseless.RailPieceLayers, - curved_rail_vertical_left_bottom = Baseless.RailPieceLayers, - curved_rail_horizontal_left_top = Baseless.RailPieceLayers, - curved_rail_horizontal_right_top = Baseless.RailPieceLayers, - curved_rail_horizontal_right_bottom = Baseless.RailPieceLayers, - curved_rail_horizontal_left_bottom = Baseless.RailPieceLayers, - rail_endings = Baseless.Sprite8Way, -} - -function CreateRail (type, prototype) - return CreateEntityWithHealth( - type, - MergeTables( - prototype, - { - pictures = Baseless.RailPictures, - } - ) - ) -end diff --git a/helpers/CreateRailSignalBase.lua b/helpers/CreateRailSignalBase.lua deleted file mode 100644 index 28440f9..0000000 --- a/helpers/CreateRailSignalBase.lua +++ /dev/null @@ -1,11 +0,0 @@ -function CreateRailSignalBase (type, prototype) - return CreateEntityWithHealth( - type, - MergeTables( - prototype, - { - animation = Baseless.RotatedAnimation, - } - ) - ) -end diff --git a/helpers/CreateRobotWithLogisticInterface.lua b/helpers/CreateRobotWithLogisticInterface.lua deleted file mode 100644 index 451ac51..0000000 --- a/helpers/CreateRobotWithLogisticInterface.lua +++ /dev/null @@ -1,12 +0,0 @@ -function CreateRobotWithLogisticInterface (type, prototype) - return CreateFlyingRobot( - type, - MergeTables( - prototype, - { - cargo_centered = {0, 0}, - max_payload_size = 1, - } - ) - ) -end diff --git a/helpers/CreateRollingStock.lua b/helpers/CreateRollingStock.lua deleted file mode 100644 index d78be8e..0000000 --- a/helpers/CreateRollingStock.lua +++ /dev/null @@ -1,19 +0,0 @@ -function CreateRollingStock (type, prototype) - return CreateVehicle( - type, - MergeTables( - prototype, - { - air_resistance = 1, - connection_distance = 1, - joint_distance = 2, -- Must be compatible with collision_box - max_speed = 1, - pictures = Baseless.RotatedSprite, - vertical_selection_shift = 1, - - -- Required for joint_distance to work - collision_box = {{-0.1, -2}, {0.1, 2}}, - } - ) - ) -end diff --git a/helpers/CreateSelectionTool.lua b/helpers/CreateSelectionTool.lua deleted file mode 100644 index c4b081a..0000000 --- a/helpers/CreateSelectionTool.lua +++ /dev/null @@ -1,16 +0,0 @@ -function CreateSelectionTool (type, prototype) - return CreateItemWithLabel( - type, - MergeTables( - prototype, - { - alt_selection_color = Baseless.Color, - alt_selection_cursor_box_type = "not-allowed", - alt_selection_mode = {"nothing"}, - selection_color = Baseless.Color, - selection_cursor_box_type = "not-allowed", - selection_mode = {"nothing"}, - } - ) - ) -end diff --git a/helpers/CreateSmoke.lua b/helpers/CreateSmoke.lua deleted file mode 100644 index 0241b04..0000000 --- a/helpers/CreateSmoke.lua +++ /dev/null @@ -1,11 +0,0 @@ -function CreateSmoke (type, prototype) - return CreateEntity( - type, - MergeTables( - prototype, - { - animation = Baseless.Animation, - } - ) - ) -end diff --git a/helpers/CreateTool.lua b/helpers/CreateTool.lua deleted file mode 100644 index 9572c37..0000000 --- a/helpers/CreateTool.lua +++ /dev/null @@ -1,11 +0,0 @@ -function CreateTool (type, prototype) - return CreateItem( - type, - MergeTables( - prototype, - { - infinite = true, - } - ) - ) -end diff --git a/helpers/CreateTransportBeltConnectable.lua b/helpers/CreateTransportBeltConnectable.lua deleted file mode 100644 index 9cd0411..0000000 --- a/helpers/CreateTransportBeltConnectable.lua +++ /dev/null @@ -1,20 +0,0 @@ -function CreateTransportBeltConnectable (type, prototype) - return CreateEntityWithHealth( - type, - MergeTables( - prototype, - { - speed = 1, - belt_horizontal = Baseless.Animation, - belt_vertical = Baseless.Animation, - ending_bottom = Baseless.Animation, - ending_side = Baseless.Animation, - ending_top = Baseless.Animation, - starting_bottom = Baseless.Animation, - starting_side = Baseless.Animation, - starting_top = Baseless.Animation, - collision_box = {{-1, -1}, {1, 1}}, - } - ) - ) -end diff --git a/helpers/CreateTurret.lua b/helpers/CreateTurret.lua deleted file mode 100644 index 8bd40c6..0000000 --- a/helpers/CreateTurret.lua +++ /dev/null @@ -1,17 +0,0 @@ -function CreateTurret (type, prototype) - if CreateEntityWithHealth( - type, - MergeTables( - prototype, - { - attack_parameters = Baseless.AttackParameters.Stream(), - call_for_help_radius = 0, - folded_animation = Baseless.RotatedAnimation4Way, - } - ) - ) then - Baseless.AttackParameters.Stream(true) - return true - end - return false -end diff --git a/helpers/CreateVehicle.lua b/helpers/CreateVehicle.lua deleted file mode 100644 index 5f38676..0000000 --- a/helpers/CreateVehicle.lua +++ /dev/null @@ -1,14 +0,0 @@ -function CreateVehicle (type, prototype) - return CreateEntityWithHealth( - type, - MergeTables( - prototype, - { - braking_force = 1, - energy_per_hit_point = 1, - friction_force = 1, - weight = 1, - } - ) - ) -end diff --git a/helpers/MergeTables.lua b/helpers/MergeTables.lua deleted file mode 100644 index 29507c4..0000000 --- a/helpers/MergeTables.lua +++ /dev/null @@ -1,13 +0,0 @@ --- Combine multiple tables into one --- --- *Tables should not share keys --- *Values are not deep copies -function MergeTables(...) - local newTable = {} - for _, table in pairs({...}) do - for key, value in pairs(table) do - newTable[key] = value - end - end - return newTable -end diff --git a/info.json b/info.json index e8900aa..6da5f7a 100644 --- a/info.json +++ b/info.json @@ -7,7 +7,5 @@ "contact": "david@skrundz.ca", "homepage": "https://github.com/DavidSkrundz/Baseless", "factorio_version": "0.18", - "dependencies": [ - "! base" - ] + "dependencies": [] } diff --git a/package.py b/package.py index 08a3439..393f017 100644 --- a/package.py +++ b/package.py @@ -8,9 +8,13 @@ modFiles = [ "info.json", "changelog.txt", "thumbnail.png", + + "data.lua", + "data-final-fixes.lua", ] modFolders = [ - "helpers", + "Baseless", + "Helpers", "prototypes", ] diff --git a/prototype.py b/prototype.py new file mode 100644 index 0000000..1fbc0ce --- /dev/null +++ b/prototype.py @@ -0,0 +1,12 @@ +#!/usr/bin/env python3 + +import os + +with open(os.path.join("prototypes", "constructors.lua"), "w+") as data: + for root, dirs, files in os.walk(os.path.join("prototypes", "constructors")): + for file in files: + fileParts = os.path.splitext(file) + if fileParts[1] != '.lua': + continue + filePath = os.path.join(root, fileParts[0]) + data.write('require("{}")\n'.format(filePath.replace(os.sep, '.'))) diff --git a/prototypes/category/ammo.lua b/prototypes/category/ammo.lua deleted file mode 100644 index b54dd26..0000000 --- a/prototypes/category/ammo.lua +++ /dev/null @@ -1,3 +0,0 @@ -if Baseless.Needs.AmmoType then - CreatePrototype("ammo-category", {}) -end diff --git a/prototypes/category/damage.lua b/prototypes/category/damage.lua deleted file mode 100644 index ccc09a9..0000000 --- a/prototypes/category/damage.lua +++ /dev/null @@ -1,26 +0,0 @@ -if data.raw["damage-type"] == nil or - data.raw["damage-type"]["physical"] == nil then - data:extend - { - { - type = "damage-type", - name = "physical", - }, - } -end - -if data.raw["damage-type"] == nil or - data.raw["damage-type"]["impact"] == nil then - data:extend - { - { - type = "damage-type", - name = "impact", - }, - } -end - - -if Baseless.Needs.DamageType then - CreatePrototype("damage-type", {}) -end diff --git a/prototypes/category/equipment.lua b/prototypes/category/equipment.lua deleted file mode 100644 index 32d9885..0000000 --- a/prototypes/category/equipment.lua +++ /dev/null @@ -1,3 +0,0 @@ -if Baseless.Needs.EquipmentType then - CreatePrototype("equipment-category", {}) -end diff --git a/prototypes/category/fuel.lua b/prototypes/category/fuel.lua deleted file mode 100644 index 484d09b..0000000 --- a/prototypes/category/fuel.lua +++ /dev/null @@ -1,3 +0,0 @@ -if Baseless.Needs.FuelType then - CreatePrototype("fuel-category", {}) -end diff --git a/prototypes/category/module.lua b/prototypes/category/module.lua deleted file mode 100644 index 5a7aed6..0000000 --- a/prototypes/category/module.lua +++ /dev/null @@ -1,3 +0,0 @@ -if Baseless.Needs.ModuleType then - CreatePrototype("module-category", {}) -end diff --git a/prototypes/category/recipe.lua b/prototypes/category/recipe.lua deleted file mode 100644 index b5658ca..0000000 --- a/prototypes/category/recipe.lua +++ /dev/null @@ -1,14 +0,0 @@ -if data.raw["recipe-category"] == nil or - data.raw["recipe-category"]["crafting"] == nil then - data:extend - { - { - type = "recipe-category", - name = "crafting", - }, - } -end - -if Baseless.Needs.RecipeType then - CreatePrototype("recipe-category", {}) -end diff --git a/prototypes/category/resource.lua b/prototypes/category/resource.lua deleted file mode 100644 index a137a44..0000000 --- a/prototypes/category/resource.lua +++ /dev/null @@ -1,14 +0,0 @@ -if data.raw["resource-category"] == nil or - data.raw["resource-category"]["basic-solid"] == nil then - data:extend - { - { - type = "resource-category", - name = "basic-solid", - }, - } -end - -if Baseless.Needs.ResourceType then - CreatePrototype("resource-category", {}) -end diff --git a/prototypes/category/trigger-target.lua b/prototypes/category/trigger-target.lua deleted file mode 100644 index 690c24b..0000000 --- a/prototypes/category/trigger-target.lua +++ /dev/null @@ -1,21 +0,0 @@ -if data.raw["trigger-target-type"] == nil or - data.raw["trigger-target-type"]["common"] == nil then - data:extend - { - { - type = "trigger-target-type", - name = "common", - }, - } -end - -if data.raw["trigger-target-type"] == nil or - data.raw["trigger-target-type"]["ground-unit"] == nil then - data:extend - { - { - type = "trigger-target-type", - name = "ground-unit", - }, - } -end diff --git a/prototypes/conditional.lua b/prototypes/conditional.lua new file mode 100644 index 0000000..1d8a162 --- /dev/null +++ b/prototypes/conditional.lua @@ -0,0 +1,22 @@ +local function RegisterConditionals(conditionals) + for key, value in pairs(conditionals) do + if Baseless.Needs[key] then + Baseless.RegisterIfNew(value) + end + end +end + +RegisterConditionals { + AmmoType = Baseless.Make.AmmoCategory(), + EquipmentType = Baseless.Make.EquipmentCategory(), + FuelType = Baseless.Make.FuelCategory(), + ModuleType = Baseless.Make.ModuleCategory(), + ResourceType = Baseless.Make.ResourceCategory(), + RecipeType = Baseless.Make.RecipeCategory(), + GunItem = Baseless.Make.Gun(), + RailEntity = { Baseless.Make.CurvedRail(), Baseless.Make.StraightRail()} , + RocketEntity = Baseless.Make.RocketSiloRocket(), + UnitEntity = Baseless.Make.Unit(), + Fluid = Baseless.Make.Fluid(), + Particle = Baseless.Make.Particle(), +} diff --git a/prototypes/constructors.lua b/prototypes/constructors.lua new file mode 100644 index 0000000..a0b81a2 --- /dev/null +++ b/prototypes/constructors.lua @@ -0,0 +1,154 @@ +require("prototypes.constructors.AmmoCategory") +require("prototypes.constructors.Base") +require("prototypes.constructors.DamageType") +require("prototypes.constructors.Entity") +require("prototypes.constructors.Equipment") +require("prototypes.constructors.EquipmentCategory") +require("prototypes.constructors.EquipmentGrid") +require("prototypes.constructors.Fluid") +require("prototypes.constructors.FuelCategory") +require("prototypes.constructors.Item") +require("prototypes.constructors.ItemGroup") +require("prototypes.constructors.ItemSubGroup") +require("prototypes.constructors.ModuleCategory") +require("prototypes.constructors.Particle") +require("prototypes.constructors.RecipeCategory") +require("prototypes.constructors.ResourceCategory") +require("prototypes.constructors.Tile") +require("prototypes.constructors.TrivialSmoke") +require("prototypes.constructors.VirtualSignal") +require("prototypes.constructors.Entity.Arrow") +require("prototypes.constructors.Entity.ArtilleryFlare") +require("prototypes.constructors.Entity.ArtilleryProjectile") +require("prototypes.constructors.Entity.Beam") +require("prototypes.constructors.Entity.CharacterCorpse") +require("prototypes.constructors.Entity.Cliff") +require("prototypes.constructors.Entity.Corpse") +require("prototypes.constructors.Entity.DeconstructibleTileProxy") +require("prototypes.constructors.Entity.EntityGhost") +require("prototypes.constructors.Entity.EntityWithHealth") +require("prototypes.constructors.Entity.Explosion") +require("prototypes.constructors.Entity.FireFlame") +require("prototypes.constructors.Entity.FluidStream") +require("prototypes.constructors.Entity.FlyingText") +require("prototypes.constructors.Entity.HighlightBoxEntity") +require("prototypes.constructors.Entity.ItemEntity") +require("prototypes.constructors.Entity.ItemRequestProxy") +require("prototypes.constructors.Entity.ParticleSource") +require("prototypes.constructors.Entity.Projectile") +require("prototypes.constructors.Entity.ResourceEntity") +require("prototypes.constructors.Entity.RocketSiloRocket") +require("prototypes.constructors.Entity.RocketSiloRocketShadow") +require("prototypes.constructors.Entity.Smoke") +require("prototypes.constructors.Entity.SpeechBubble") +require("prototypes.constructors.Entity.Sticker") +require("prototypes.constructors.Entity.TileGhost") +require("prototypes.constructors.Entity.Corpse.RailRemnants") +require("prototypes.constructors.Entity.EntityWithHealth.Accumulator") +require("prototypes.constructors.Entity.EntityWithHealth.ArtilleryTurret") +require("prototypes.constructors.Entity.EntityWithHealth.Beacon") +require("prototypes.constructors.Entity.EntityWithHealth.Boiler") +require("prototypes.constructors.Entity.EntityWithHealth.BurnerGenerator") +require("prototypes.constructors.Entity.EntityWithHealth.Character") +require("prototypes.constructors.Entity.EntityWithHealth.Combinator") +require("prototypes.constructors.Entity.EntityWithHealth.ConstantCombinator") +require("prototypes.constructors.Entity.EntityWithHealth.Container") +require("prototypes.constructors.Entity.EntityWithHealth.CraftingMachine") +require("prototypes.constructors.Entity.EntityWithHealth.ElectricEnergyInterface") +require("prototypes.constructors.Entity.EntityWithHealth.ElectricPole") +require("prototypes.constructors.Entity.EntityWithHealth.EnemySpawner") +require("prototypes.constructors.Entity.EntityWithHealth.Fish") +require("prototypes.constructors.Entity.EntityWithHealth.FlyingRobot") +require("prototypes.constructors.Entity.EntityWithHealth.Gate") +require("prototypes.constructors.Entity.EntityWithHealth.Generator") +require("prototypes.constructors.Entity.EntityWithHealth.HeatInterface") +require("prototypes.constructors.Entity.EntityWithHealth.HeatPipe") +require("prototypes.constructors.Entity.EntityWithHealth.Inserter") +require("prototypes.constructors.Entity.EntityWithHealth.Lab") +require("prototypes.constructors.Entity.EntityWithHealth.Lamp") +require("prototypes.constructors.Entity.EntityWithHealth.LandMine") +require("prototypes.constructors.Entity.EntityWithHealth.Market") +require("prototypes.constructors.Entity.EntityWithHealth.MiningDrill") +require("prototypes.constructors.Entity.EntityWithHealth.OffshorePump") +require("prototypes.constructors.Entity.EntityWithHealth.Pipe") +require("prototypes.constructors.Entity.EntityWithHealth.PipeToGround") +require("prototypes.constructors.Entity.EntityWithHealth.PlayerPort") +require("prototypes.constructors.Entity.EntityWithHealth.PowerSwitch") +require("prototypes.constructors.Entity.EntityWithHealth.ProgrammableSpeaker") +require("prototypes.constructors.Entity.EntityWithHealth.Pump") +require("prototypes.constructors.Entity.EntityWithHealth.Radar") +require("prototypes.constructors.Entity.EntityWithHealth.Rail") +require("prototypes.constructors.Entity.EntityWithHealth.RailSignalBase") +require("prototypes.constructors.Entity.EntityWithHealth.Reactor") +require("prototypes.constructors.Entity.EntityWithHealth.Roboport") +require("prototypes.constructors.Entity.EntityWithHealth.SimpleEntity") +require("prototypes.constructors.Entity.EntityWithHealth.SimpleEntityWithForce") +require("prototypes.constructors.Entity.EntityWithHealth.SimpleEntityWithOwner") +require("prototypes.constructors.Entity.EntityWithHealth.SolarPanel") +require("prototypes.constructors.Entity.EntityWithHealth.StorageTank") +require("prototypes.constructors.Entity.EntityWithHealth.TrainStop") +require("prototypes.constructors.Entity.EntityWithHealth.TransportBeltConnectable") +require("prototypes.constructors.Entity.EntityWithHealth.Tree") +require("prototypes.constructors.Entity.EntityWithHealth.Turret") +require("prototypes.constructors.Entity.EntityWithHealth.Unit") +require("prototypes.constructors.Entity.EntityWithHealth.Vehicle") +require("prototypes.constructors.Entity.EntityWithHealth.Wall") +require("prototypes.constructors.Entity.EntityWithHealth.Combinator.ArithmeticCombinator") +require("prototypes.constructors.Entity.EntityWithHealth.Combinator.DeciderCombinator") +require("prototypes.constructors.Entity.EntityWithHealth.Container.LogisticContainer") +require("prototypes.constructors.Entity.EntityWithHealth.Container.LogisticContainer.InfinityContainer") +require("prototypes.constructors.Entity.EntityWithHealth.CraftingMachine.AssemblingMachine") +require("prototypes.constructors.Entity.EntityWithHealth.CraftingMachine.Furnace") +require("prototypes.constructors.Entity.EntityWithHealth.CraftingMachine.AssemblingMachine.RocketSilo") +require("prototypes.constructors.Entity.EntityWithHealth.FlyingRobot.CombatRobot") +require("prototypes.constructors.Entity.EntityWithHealth.FlyingRobot.RobotWithLogisticInterface") +require("prototypes.constructors.Entity.EntityWithHealth.FlyingRobot.RobotWithLogisticInterface.ConstructionRobot") +require("prototypes.constructors.Entity.EntityWithHealth.FlyingRobot.RobotWithLogisticInterface.LogisticRobot") +require("prototypes.constructors.Entity.EntityWithHealth.Pipe.InfinityPipe") +require("prototypes.constructors.Entity.EntityWithHealth.Rail.CurvedRail") +require("prototypes.constructors.Entity.EntityWithHealth.Rail.StraightRail") +require("prototypes.constructors.Entity.EntityWithHealth.RailSignalBase.RailChainSignal") +require("prototypes.constructors.Entity.EntityWithHealth.RailSignalBase.RailSignal") +require("prototypes.constructors.Entity.EntityWithHealth.TransportBeltConnectable.Loader1x1") +require("prototypes.constructors.Entity.EntityWithHealth.TransportBeltConnectable.Loader1x2") +require("prototypes.constructors.Entity.EntityWithHealth.TransportBeltConnectable.Splitter") +require("prototypes.constructors.Entity.EntityWithHealth.TransportBeltConnectable.TransportBelt") +require("prototypes.constructors.Entity.EntityWithHealth.TransportBeltConnectable.UndergroundBelt") +require("prototypes.constructors.Entity.EntityWithHealth.Turret.AmmoTurret") +require("prototypes.constructors.Entity.EntityWithHealth.Turret.ElectricTurret") +require("prototypes.constructors.Entity.EntityWithHealth.Turret.FluidTurret") +require("prototypes.constructors.Entity.EntityWithHealth.Vehicle.Car") +require("prototypes.constructors.Entity.EntityWithHealth.Vehicle.RollingStock") +require("prototypes.constructors.Entity.EntityWithHealth.Vehicle.RollingStock.ArtilleryWagon") +require("prototypes.constructors.Entity.EntityWithHealth.Vehicle.RollingStock.CargoWagon") +require("prototypes.constructors.Entity.EntityWithHealth.Vehicle.RollingStock.FluidWagon") +require("prototypes.constructors.Entity.EntityWithHealth.Vehicle.RollingStock.Locomotive") +require("prototypes.constructors.Entity.Explosion.FlameThrowerExplosion") +require("prototypes.constructors.Entity.Smoke.SmokeWithTrigger") +require("prototypes.constructors.Equipment.ActiveDefenseEquipment") +require("prototypes.constructors.Equipment.BatteryEquipment") +require("prototypes.constructors.Equipment.BeltImmunityEquipment") +require("prototypes.constructors.Equipment.EnergyShieldEquipment") +require("prototypes.constructors.Equipment.GeneratorEquipment") +require("prototypes.constructors.Equipment.MovementBonusEquipment") +require("prototypes.constructors.Equipment.NightVisionEquipment") +require("prototypes.constructors.Equipment.RoboportEquipment") +require("prototypes.constructors.Equipment.SolarPanelEquipment") +require("prototypes.constructors.Item.Ammo") +require("prototypes.constructors.Item.Capsule") +require("prototypes.constructors.Item.Gun") +require("prototypes.constructors.Item.ItemWithEntityData") +require("prototypes.constructors.Item.ItemWithLabel") +require("prototypes.constructors.Item.Module") +require("prototypes.constructors.Item.RailPlanner") +require("prototypes.constructors.Item.Tool") +require("prototypes.constructors.Item.ItemWithLabel.ItemWithInventory") +require("prototypes.constructors.Item.ItemWithLabel.ItemWithTags") +require("prototypes.constructors.Item.ItemWithLabel.SelectionTool") +require("prototypes.constructors.Item.ItemWithLabel.ItemWithInventory.BlueprintBook") +require("prototypes.constructors.Item.ItemWithLabel.SelectionTool.Blueprint") +require("prototypes.constructors.Item.ItemWithLabel.SelectionTool.CopyPasteTool") +require("prototypes.constructors.Item.ItemWithLabel.SelectionTool.DeconstructionItem") +require("prototypes.constructors.Item.ItemWithLabel.SelectionTool.UpgradeItem") +require("prototypes.constructors.Item.Tool.Armor") +require("prototypes.constructors.Item.Tool.RepairTool") diff --git a/prototypes/constructors/AmmoCategory.lua b/prototypes/constructors/AmmoCategory.lua new file mode 100644 index 0000000..e517d29 --- /dev/null +++ b/prototypes/constructors/AmmoCategory.lua @@ -0,0 +1,3 @@ +Baseless.Make.AmmoCategory = function (name, prototype) + return Baseless.Make.Base("ammo-category", name, prototype) +end diff --git a/prototypes/constructors/Base.lua b/prototypes/constructors/Base.lua new file mode 100644 index 0000000..6a4123b --- /dev/null +++ b/prototypes/constructors/Base.lua @@ -0,0 +1,10 @@ +Baseless.Make.Base = function (type, name, prototype, conditions) + return Merge( + { + type = type, + name = name or "dummy-" .. type, + baseless_conditions = conditions, -- Conditions to enable when Registered + }, + prototype + ) +end diff --git a/prototypes/constructors/DamageType.lua b/prototypes/constructors/DamageType.lua new file mode 100644 index 0000000..7bc7b2e --- /dev/null +++ b/prototypes/constructors/DamageType.lua @@ -0,0 +1,3 @@ +Baseless.Make.DamageType = function (name, prototype) + return Baseless.Make.Base("damage-type", name, prototype) +end diff --git a/prototypes/constructors/Entity.lua b/prototypes/constructors/Entity.lua new file mode 100644 index 0000000..9a7da2a --- /dev/null +++ b/prototypes/constructors/Entity.lua @@ -0,0 +1,8 @@ +Baseless.Make.Entity = function (type, name, prototype, conditions) + return Baseless.Make.Base(type, name, Merge( + Baseless.Graphics.IconSpecification, + { + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Entity/Arrow.lua b/prototypes/constructors/Entity/Arrow.lua new file mode 100644 index 0000000..bd8e0bc --- /dev/null +++ b/prototypes/constructors/Entity/Arrow.lua @@ -0,0 +1,8 @@ +Baseless.Make.Arrow = function (name, prototype) + return Baseless.Make.Entity("arrow", name, Merge( + { + arrow_picture = Baseless.Graphics.Sprite, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/ArtilleryFlare.lua b/prototypes/constructors/Entity/ArtilleryFlare.lua new file mode 100644 index 0000000..c789cc9 --- /dev/null +++ b/prototypes/constructors/Entity/ArtilleryFlare.lua @@ -0,0 +1,10 @@ +Baseless.Make.ArtilleryFlare = function (name, prototype) + return Baseless.Make.Entity("artillery-flare", name, Merge( + { + life_time = 0, + pictures = Baseless.Graphics.AnimationVariations, + map_color = Baseless.Data.Color, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/ArtilleryProjectile.lua b/prototypes/constructors/Entity/ArtilleryProjectile.lua new file mode 100644 index 0000000..4f32e2a --- /dev/null +++ b/prototypes/constructors/Entity/ArtilleryProjectile.lua @@ -0,0 +1,9 @@ +Baseless.Make.ArtilleryProjectile = function (name, prototype) + return Baseless.Make.Entity("artillery-projectile", name, Merge( + { + reveal_map = false, + map_color = Baseless.Data.Color, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/Beam.lua b/prototypes/constructors/Entity/Beam.lua new file mode 100644 index 0000000..7defd6e --- /dev/null +++ b/prototypes/constructors/Entity/Beam.lua @@ -0,0 +1,12 @@ +Baseless.Make.Beam = function (name, prototype) + return Baseless.Make.Entity("beam", name, Merge( + { + body = Baseless.Graphics.AnimationVariations, + damage_interval = 1, + head = Baseless.Graphics.Animation, + tail = Baseless.Graphics.Animation, + width = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/CharacterCorpse.lua b/prototypes/constructors/Entity/CharacterCorpse.lua new file mode 100644 index 0000000..353cf16 --- /dev/null +++ b/prototypes/constructors/Entity/CharacterCorpse.lua @@ -0,0 +1,9 @@ +Baseless.Make.CharacterCorpse = function (name, prototype) + return Baseless.Make.Entity("character-corpse", name, Merge( + { + time_to_live = 0, + picture = Baseless.Graphics.Animation, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/Cliff.lua b/prototypes/constructors/Entity/Cliff.lua new file mode 100644 index 0000000..577389f --- /dev/null +++ b/prototypes/constructors/Entity/Cliff.lua @@ -0,0 +1,41 @@ +local OrientedCliffPrototype = +{ + collision_bounding_box = Baseless.Data.BoundingBox, + pictures = Baseless.Graphics.SpriteVariations, + fill_volume = 1, +} +local CliffOrientations = +{ + west_to_east = OrientedCliffPrototype, + north_to_south = OrientedCliffPrototype, + east_to_west = OrientedCliffPrototype, + south_to_north = OrientedCliffPrototype, + west_to_north = OrientedCliffPrototype, + north_to_east = OrientedCliffPrototype, + east_to_south = OrientedCliffPrototype, + south_to_west = OrientedCliffPrototype, + west_to_south = OrientedCliffPrototype, + north_to_west = OrientedCliffPrototype, + east_to_north = OrientedCliffPrototype, + south_to_east = OrientedCliffPrototype, + west_to_none = OrientedCliffPrototype, + none_to_east = OrientedCliffPrototype, + north_to_none = OrientedCliffPrototype, + none_to_south = OrientedCliffPrototype, + east_to_none = OrientedCliffPrototype, + none_to_west = OrientedCliffPrototype, + south_to_none = OrientedCliffPrototype, + none_to_north = OrientedCliffPrototype, +} + + +Baseless.Make.Cliff = function (name, prototype) + return Baseless.Make.Entity("cliff", name, Merge( + { + grid_offset = Baseless.Data.Vector.Zero, + grid_size = Baseless.Data.Vector.One, + orientations = CliffOrientations, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/Corpse.lua b/prototypes/constructors/Entity/Corpse.lua new file mode 100644 index 0000000..3425c75 --- /dev/null +++ b/prototypes/constructors/Entity/Corpse.lua @@ -0,0 +1,7 @@ +Baseless.Make.Corpse = function (type, name, prototype, conditions) + return Baseless.Make.Entity(type or "corpse", name, Merge( + { + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Entity/Corpse/RailRemnants.lua b/prototypes/constructors/Entity/Corpse/RailRemnants.lua new file mode 100644 index 0000000..893560d --- /dev/null +++ b/prototypes/constructors/Entity/Corpse/RailRemnants.lua @@ -0,0 +1,11 @@ +Baseless.Make.RailRemnants = function (name, prototype) + return Baseless.Make.Corpse("rail-remnants", name, Merge( + { + bending_type = "turn", + pictures = Baseless.Graphics.RailPictures, + collision_box = Baseless.Data.BoundingBox, + secondary_collision_box = Baseless.Data.BoundingBox, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/DeconstructibleTileProxy.lua b/prototypes/constructors/Entity/DeconstructibleTileProxy.lua new file mode 100644 index 0000000..4554a34 --- /dev/null +++ b/prototypes/constructors/Entity/DeconstructibleTileProxy.lua @@ -0,0 +1,7 @@ +Baseless.Make.DeconstructibleTileProxy = function (name, prototype) + return Baseless.Make.Entity("deconstructible-tile-proxy", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityGhost.lua b/prototypes/constructors/Entity/EntityGhost.lua new file mode 100644 index 0000000..b141b22 --- /dev/null +++ b/prototypes/constructors/Entity/EntityGhost.lua @@ -0,0 +1,7 @@ +Baseless.Make.EntityGhost = function (name, prototype) + return Baseless.Make.Entity("entity-ghost", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth.lua b/prototypes/constructors/Entity/EntityWithHealth.lua new file mode 100644 index 0000000..4a093de --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth.lua @@ -0,0 +1,7 @@ +Baseless.Make.EntityWithHealth = function (type, name, prototype, conditions) + return Baseless.Make.Entity(type, name, Merge( + { + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Accumulator.lua b/prototypes/constructors/Entity/EntityWithHealth/Accumulator.lua new file mode 100644 index 0000000..d7319e4 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Accumulator.lua @@ -0,0 +1,11 @@ +Baseless.Make.Accumulator = function (name, prototype) + return Baseless.Make.EntityWithHealth("accumulator", name, Merge( + { + charge_cooldown = 0, + discharge_cooldown = 0, + energy_source = Baseless.Data.EnergySource.Electric, + picture = Baseless.Graphics.Sprite, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/ArtilleryTurret.lua b/prototypes/constructors/Entity/EntityWithHealth/ArtilleryTurret.lua new file mode 100644 index 0000000..2046518 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/ArtilleryTurret.lua @@ -0,0 +1,13 @@ +Baseless.Make.ArtilleryTurret = function (name, prototype) + return Baseless.Make.EntityWithHealth("artillery-turret", name, Merge( + { + ammo_stack_limit = 1, + automated_ammo_count = 0, + gun = Baseless.Data.GunItem, + inventory_size = 1, + manual_range_modifier = 1, + turret_rotation_speed = 0, + }, + prototype + ), {"GunItem"}) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Beacon.lua b/prototypes/constructors/Entity/EntityWithHealth/Beacon.lua new file mode 100644 index 0000000..eb861ee --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Beacon.lua @@ -0,0 +1,15 @@ +Baseless.Make.Beacon = function (name, prototype) + return Baseless.Make.EntityWithHealth("beacon", name, Merge( + { + animation = Baseless.Graphics.Animation, + animation_shadow = Baseless.Graphics.Animation, + base_picture = Baseless.Graphics.Sprite, + distribution_effectivity = 0, + energy_source = Baseless.Data.EnergySource.Electric, + energy_usage = Baseless.Data.Energy, + module_specification = Baseless.Data.ModuleSpecification, + supply_area_distance = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Boiler.lua b/prototypes/constructors/Entity/EntityWithHealth/Boiler.lua new file mode 100644 index 0000000..5c361f8 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Boiler.lua @@ -0,0 +1,22 @@ +Baseless.Make.Boiler = function (name, prototype) + return Baseless.Make.EntityWithHealth("boiler", name, Merge( + { + burning_cooldown = 0, + energy_consumption = Baseless.Data.Energy, + energy_source = Baseless.Data.EnergySource.Electric, + fire = {}, + fire_glow = {}, + fluid_box = Baseless.Data.FluidBox, + output_fluid_box = Baseless.Data.FluidBox, + structure = + { + north = Baseless.Graphics.Sprite, + south = Baseless.Graphics.Sprite, + east = Baseless.Graphics.Sprite, + west = Baseless.Graphics.Sprite, + }, + target_temperature = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/BurnerGenerator.lua b/prototypes/constructors/Entity/EntityWithHealth/BurnerGenerator.lua new file mode 100644 index 0000000..d82a055 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/BurnerGenerator.lua @@ -0,0 +1,11 @@ +Baseless.Make.BurnerGenerator = function (name, prototype) + return Baseless.Make.EntityWithHealth("burner-generator", name, Merge( + { + animation = Baseless.Graphics.Animation4Way, + burner = Baseless.Data.EnergySource.Burner, + energy_source = Baseless.Data.EnergySource.Electric, + max_power_output = Baseless.Data.Energy, + }, + prototype + ), {"FuelType"}) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Character.lua b/prototypes/constructors/Entity/EntityWithHealth/Character.lua new file mode 100644 index 0000000..632f5cc --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Character.lua @@ -0,0 +1,42 @@ +local RotatedAnimation32 = Merge( + Baseless.Graphics.RotatedAnimation32, + { + direction_count = 18, + } +) +local CharacterArmorAnimation = +{ + idle = RotatedAnimation32, + idle_with_gun = RotatedAnimation32, + running = RotatedAnimation32, + running_with_gun = RotatedAnimation32, + mining_with_tool = RotatedAnimation32, +} + +Baseless.Make.Character = function (name, prototype) + return Baseless.Make.EntityWithHealth("character", name, Merge( + { + animations = {CharacterArmorAnimation}, + build_distance = 0, + damage_hit_tint = Baseless.Data.Color, + distance_per_frame = 0, + drop_item_distance = 0, + eat = Baseless.Sound, + heartbeat = Baseless.Sound, + inventory_size = 0, + item_pickup_distance = 0, + loot_pickup_distance = 0, + maximum_corner_sliding_distance = 0, + mining_speed = 0, + mining_with_tool_particles_animation_positions = {}, + reach_distance = 0, + reach_resource_distance = 0, + running_sound_animation_positions = {}, + running_speed = 0, + ticks_to_keep_aiming_direction = 0, + ticks_to_keep_gun = 0, + ticks_to_stay_in_combat = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Combinator.lua b/prototypes/constructors/Entity/EntityWithHealth/Combinator.lua new file mode 100644 index 0000000..ac61a18 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Combinator.lua @@ -0,0 +1,32 @@ +local WireConnectionPoint = +{ + {wire = {}, shadow = {}}, + {wire = {}, shadow = {}}, + {wire = {}, shadow = {}}, + {wire = {}, shadow = {}}, +} +local Offsets = +{ + {0, 0}, + {0, 0}, + {0, 0}, + {0, 0}, +} + +Baseless.Make.Combinator = function (type, name, prototype, conditions) + return Baseless.Make.EntityWithHealth(type, name, Merge( + { + active_energy_usage = Baseless.Data.Energy, + activity_led_light_offsets = Offsets, + activity_led_sprites = Baseless.Graphics.Sprite4Way, + energy_source = Baseless.Data.EnergySource.Electric, + input_connection_bounding_box = Baseless.Data.BoundingBox, + input_connection_points = WireConnectionPoint, + output_connection_bounding_box = Baseless.Data.BoundingBox, + output_connection_points = WireConnectionPoint, + screen_light_offsets = Offsets, + sprites = Baseless.Graphics.Sprite4Way, + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Combinator/ArithmeticCombinator.lua b/prototypes/constructors/Entity/EntityWithHealth/Combinator/ArithmeticCombinator.lua new file mode 100644 index 0000000..1cd9256 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Combinator/ArithmeticCombinator.lua @@ -0,0 +1,18 @@ +Baseless.Make.ArithmeticCombinator = function (name, prototype) + return Baseless.Make.Combinator("arithmetic-combinator", name, Merge( + { + and_symbol_sprites = Baseless.Graphics.Sprite4Way, + divide_symbol_sprites = Baseless.Graphics.Sprite4Way, + left_shift_symbol_sprites = Baseless.Graphics.Sprite4Way, + minus_symbol_sprites = Baseless.Graphics.Sprite4Way, + modulo_symbol_sprites = Baseless.Graphics.Sprite4Way, + multiply_symbol_sprites = Baseless.Graphics.Sprite4Way, + or_symbol_sprites = Baseless.Graphics.Sprite4Way, + plus_symbol_sprites = Baseless.Graphics.Sprite4Way, + power_symbol_sprites = Baseless.Graphics.Sprite4Way, + right_shift_symbol_sprites = Baseless.Graphics.Sprite4Way, + xor_symbol_sprites = Baseless.Graphics.Sprite4Way, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Combinator/DeciderCombinator.lua b/prototypes/constructors/Entity/EntityWithHealth/Combinator/DeciderCombinator.lua new file mode 100644 index 0000000..299255e --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Combinator/DeciderCombinator.lua @@ -0,0 +1,13 @@ +Baseless.Make.DeciderCombinator = function (name, prototype) + return Baseless.Make.Combinator("decider-combinator", name, Merge( + { + equal_symbol_sprites = Baseless.Graphics.Sprite4Way, + greater_or_equal_symbol_sprites = Baseless.Graphics.Sprite4Way, + greater_symbol_sprites = Baseless.Graphics.Sprite4Way, + less_or_equal_symbol_sprites = Baseless.Graphics.Sprite4Way, + less_symbol_sprites = Baseless.Graphics.Sprite4Way, + not_equal_symbol_sprites = Baseless.Graphics.Sprite4Way, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/ConstantCombinator.lua b/prototypes/constructors/Entity/EntityWithHealth/ConstantCombinator.lua new file mode 100644 index 0000000..482f3bf --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/ConstantCombinator.lua @@ -0,0 +1,27 @@ +local WireConnectionPoint = +{ + {wire = {}, shadow = {}}, + {wire = {}, shadow = {}}, + {wire = {}, shadow = {}}, + {wire = {}, shadow = {}}, +} +local Offsets = +{ + {0, 0}, + {0, 0}, + {0, 0}, + {0, 0}, +} + +Baseless.Make.ConstantCombinator = function (name, prototype) + return Baseless.Make.EntityWithHealth("constant-combinator", name, Merge( + { + activity_led_light_offsets = Offsets, + activity_led_sprites = Baseless.Graphics.Sprite4Way, + circuit_wire_connection_points = WireConnectionPoint, + item_slot_count = 0, + sprites = Baseless.Graphics.Sprite4Way, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Container.lua b/prototypes/constructors/Entity/EntityWithHealth/Container.lua new file mode 100644 index 0000000..391122b --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Container.lua @@ -0,0 +1,9 @@ +Baseless.Make.Container = function (type, name, prototype, conditions) + return Baseless.Make.EntityWithHealth(type or "container", name, Merge( + { + inventory_size = 1, + picture = Baseless.Graphics.Sprite, + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Container/LogisticContainer.lua b/prototypes/constructors/Entity/EntityWithHealth/Container/LogisticContainer.lua new file mode 100644 index 0000000..8cb5abe --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Container/LogisticContainer.lua @@ -0,0 +1,8 @@ +Baseless.Make.LogisticContainer = function (type, name, prototype, conditions) + return Baseless.Make.Container(type or "logistic-container", name, Merge( + { + logistic_mode = "storage", + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Container/LogisticContainer/InfinityContainer.lua b/prototypes/constructors/Entity/EntityWithHealth/Container/LogisticContainer/InfinityContainer.lua new file mode 100644 index 0000000..99600d6 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Container/LogisticContainer/InfinityContainer.lua @@ -0,0 +1,8 @@ +Baseless.Make.InfinityContainer = function (name, prototype) + return Baseless.Make.LogisticContainer("infinity-container", name, Merge( + { + erase_contents_when_mined = false, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/CraftingMachine.lua b/prototypes/constructors/Entity/EntityWithHealth/CraftingMachine.lua new file mode 100644 index 0000000..b623985 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/CraftingMachine.lua @@ -0,0 +1,11 @@ +Baseless.Make.CraftingMachine = function (type, name, prototype, conditions) + return Baseless.Make.EntityWithHealth(type, name, Merge( + { + crafting_categories = {Baseless.Data.RecipeType}, + crafting_speed = 1, + energy_source = Baseless.Data.EnergySource.Electric, + energy_usage = Baseless.Data.Energy, + }, + prototype + ), Append({"RecipeType"}, conditions)) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/CraftingMachine/AssemblingMachine.lua b/prototypes/constructors/Entity/EntityWithHealth/CraftingMachine/AssemblingMachine.lua new file mode 100644 index 0000000..d8ae329 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/CraftingMachine/AssemblingMachine.lua @@ -0,0 +1,7 @@ +Baseless.Make.AssemblingMachine = function (type, name, prototype, conditions) + return Baseless.Make.CraftingMachine(type or "assembling-machine", name, Merge( + { + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/CraftingMachine/AssemblingMachine/RocketSilo.lua b/prototypes/constructors/Entity/EntityWithHealth/CraftingMachine/AssemblingMachine/RocketSilo.lua new file mode 100644 index 0000000..cf52e95 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/CraftingMachine/AssemblingMachine/RocketSilo.lua @@ -0,0 +1,37 @@ +Baseless.Make.RocketSilo = function (name, prototype) + return Baseless.Make.AssemblingMachine("rocket-silo", name, Merge( + { + active_energy_usage = Baseless.Data.Energy, + arm_01_back_animation = Baseless.Graphics.Animation, + arm_02_right_animation = Baseless.Graphics.Animation, + arm_03_front_animation = Baseless.Graphics.Animation, + base_day_sprite = Baseless.Graphics.Sprite, + base_front_sprite = Baseless.Graphics.Sprite, + door_back_open_offset = Baseless.Data.Vector.Zero, + door_back_sprite = Baseless.Graphics.Sprite, + door_front_open_offset = Baseless.Data.Vector.Zero, + door_front_sprite = Baseless.Graphics.Sprite, + door_opening_speed = 0, + energy_usage = Baseless.Data.Energy, + hole_clipping_box = Baseless.Data.BoundingBox, + hole_light_sprite = Baseless.Graphics.Sprite, + hole_sprite = Baseless.Graphics.Sprite, + idle_energy_usage = Baseless.Data.Energy, + lamp_energy_usage = Baseless.Data.Energy, + light_blinking_speed = 0, + red_lights_back_sprites = Baseless.Graphics.Sprite, + red_lights_front_sprites = Baseless.Graphics.Sprite, + rocket_entity = Baseless.Data.RocketEntity, + rocket_glow_overlay_sprite = Baseless.Graphics.Sprite, + rocket_parts_required = 0, + rocket_shadow_overlay_sprite = Baseless.Graphics.Sprite, + satellite_animation = Baseless.Graphics.Animation, + satellite_shadow_animation = Baseless.Graphics.Animation, + shadow_sprite = Baseless.Graphics.Sprite, + silo_fade_out_end_distance = 0, + silo_fade_out_start_distance = 0, + times_to_blink = 0, + }, + prototype + ), {"RocketEntity"}) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/CraftingMachine/Furnace.lua b/prototypes/constructors/Entity/EntityWithHealth/CraftingMachine/Furnace.lua new file mode 100644 index 0000000..6f85764 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/CraftingMachine/Furnace.lua @@ -0,0 +1,9 @@ +Baseless.Make.Furnace = function (name, prototype) + return Baseless.Make.CraftingMachine("furnace", name, Merge( + { + result_inventory_size = 0, + source_inventory_size = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/ElectricEnergyInterface.lua b/prototypes/constructors/Entity/EntityWithHealth/ElectricEnergyInterface.lua new file mode 100644 index 0000000..e7f425d --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/ElectricEnergyInterface.lua @@ -0,0 +1,8 @@ +Baseless.Make.ElectricEnergyInterface = function (name, prototype) + return Baseless.Make.EntityWithHealth("electric-energy-interface", name, Merge( + { + energy_source = Baseless.Data.EnergySource.Electric, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/ElectricPole.lua b/prototypes/constructors/Entity/EntityWithHealth/ElectricPole.lua new file mode 100644 index 0000000..37271d4 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/ElectricPole.lua @@ -0,0 +1,15 @@ +local WireConnectionPoint = +{ + {wire = {}, shadow = {}}, +} + +Baseless.Make.ElectricPole = function (name, prototype) + return Baseless.Make.EntityWithHealth("electric-pole", name, Merge( + { + connection_points = WireConnectionPoint, + pictures = Baseless.Graphics.RotatedSprite, + supply_area_distance = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/EnemySpawner.lua b/prototypes/constructors/Entity/EntityWithHealth/EnemySpawner.lua new file mode 100644 index 0000000..1ad7076 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/EnemySpawner.lua @@ -0,0 +1,34 @@ +local UnitSpawnDefinition = +{ + { + unit = Baseless.Data.UnitEntity, + spawn_points = + { + { + evolution_factor = 0, + spawn_weight = 0, + }, + }, + }, +} +local Cooldowns = {1, 1} + +Baseless.Make.EnemySpawner = function (name, prototype) + return Baseless.Make.EntityWithHealth("unit-spawner", name, Merge( + { + animations = Baseless.Graphics.AnimationVariations, + call_for_help_radius = 0, + max_count_of_owned_units = 0, + max_friends_around_to_spawn = 0, + max_richness_for_spawn_shift = 0, + max_spawn_shift = 0, + pollution_absorption_absolute = 0, + pollution_absorption_proportional = 0, + result_units = UnitSpawnDefinition, + spawning_cooldown = Cooldowns, + spawning_radius = 0, + spawning_spacing = 0, + }, + prototype + ), {"UnitEntity"}) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Fish.lua b/prototypes/constructors/Entity/EntityWithHealth/Fish.lua new file mode 100644 index 0000000..a45439a --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Fish.lua @@ -0,0 +1,8 @@ +Baseless.Make.Fish = function (name, prototype) + return Baseless.Make.EntityWithHealth("fish", name, Merge( + { + pictures = Baseless.Graphics.SpriteVariations, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/FlyingRobot.lua b/prototypes/constructors/Entity/EntityWithHealth/FlyingRobot.lua new file mode 100644 index 0000000..1a5cf09 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/FlyingRobot.lua @@ -0,0 +1,8 @@ +Baseless.Make.FlyingRobot = function (type, name, prototype, conditions) + return Baseless.Make.EntityWithHealth(type, name, Merge( + { + speed = 0, + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/FlyingRobot/CombatRobot.lua b/prototypes/constructors/Entity/EntityWithHealth/FlyingRobot/CombatRobot.lua new file mode 100644 index 0000000..4a0ae0b --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/FlyingRobot/CombatRobot.lua @@ -0,0 +1,13 @@ +Baseless.Make.CombatRobot = function (name, prototype) + return Baseless.Make.FlyingRobot("combat-robot", name, Merge( + { + attack_parameters = Baseless.Data.AttackParameters, + idle = Baseless.Graphics.RotatedAnimation, + in_motion = Baseless.Graphics.RotatedAnimation, + shadow_idle = Baseless.Graphics.RotatedAnimation, + shadow_in_motion = Baseless.Graphics.RotatedAnimation, + time_to_live = 0, + }, + prototype + ), {"AmmoType"}) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/FlyingRobot/RobotWithLogisticInterface.lua b/prototypes/constructors/Entity/EntityWithHealth/FlyingRobot/RobotWithLogisticInterface.lua new file mode 100644 index 0000000..7642f56 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/FlyingRobot/RobotWithLogisticInterface.lua @@ -0,0 +1,9 @@ +Baseless.Make.RobotWithLogisticInterface = function (type, name, prototype, conditions) + return Baseless.Make.FlyingRobot(type, name, Merge( + { + cargo_centered = Baseless.Data.Vector.Zero, + max_payload_size = 0, + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/FlyingRobot/RobotWithLogisticInterface/ConstructionRobot.lua b/prototypes/constructors/Entity/EntityWithHealth/FlyingRobot/RobotWithLogisticInterface/ConstructionRobot.lua new file mode 100644 index 0000000..dd60efa --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/FlyingRobot/RobotWithLogisticInterface/ConstructionRobot.lua @@ -0,0 +1,8 @@ +Baseless.Make.ConstructionRobot = function (name, prototype) + return Baseless.Make.RobotWithLogisticInterface("construction-robot", name, Merge( + { + construction_vector = Baseless.Data.Vector.Zero, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/FlyingRobot/RobotWithLogisticInterface/LogisticRobot.lua b/prototypes/constructors/Entity/EntityWithHealth/FlyingRobot/RobotWithLogisticInterface/LogisticRobot.lua new file mode 100644 index 0000000..ef6acb5 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/FlyingRobot/RobotWithLogisticInterface/LogisticRobot.lua @@ -0,0 +1,7 @@ +Baseless.Make.LogisticRobot = function (name, prototype) + return Baseless.Make.RobotWithLogisticInterface("logistic-robot", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Gate.lua b/prototypes/constructors/Entity/EntityWithHealth/Gate.lua new file mode 100644 index 0000000..7cb8334 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Gate.lua @@ -0,0 +1,21 @@ +Baseless.Make.Gate = function (name, prototype) + return Baseless.Make.EntityWithHealth("gate", name, Merge( + { + activation_distance = 0, + close_sound = Baseless.Sound, + horizontal_animation = Baseless.Graphics.Animation, + horizontal_rail_animation_left = Baseless.Graphics.Animation, + horizontal_rail_animation_right = Baseless.Graphics.Animation, + horizontal_rail_base = Baseless.Graphics.Animation, + open_sound = Baseless.Sound, + opening_speed = 0, + timeout_to_close = 0, + vertical_animation = Baseless.Graphics.Animation, + vertical_rail_animation_left = Baseless.Graphics.Animation, + vertical_rail_animation_right = Baseless.Graphics.Animation, + vertical_rail_base = Baseless.Graphics.Animation, + wall_patch = Baseless.Graphics.Animation, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Generator.lua b/prototypes/constructors/Entity/EntityWithHealth/Generator.lua new file mode 100644 index 0000000..52f371d --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Generator.lua @@ -0,0 +1,15 @@ +Baseless.Make.Generator = function (name, prototype) + return Baseless.Make.EntityWithHealth("generator", name, Merge( + { + effectivity = 0, + energy_source = Baseless.Data.EnergySource.Electric, + fluid_box = Baseless.Data.FluidBox, + fluid_usage_per_tick = 0, + horizontal_animation = Baseless.Graphics.Animation, + maximum_temperature = 0, + vertical_animation = Baseless.Graphics.Animation, + max_power_output = Baseless.Data.Energy, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/HeatInterface.lua b/prototypes/constructors/Entity/EntityWithHealth/HeatInterface.lua new file mode 100644 index 0000000..d598669 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/HeatInterface.lua @@ -0,0 +1,8 @@ +Baseless.Make.HeatInterface = function (name, prototype) + return Baseless.Make.EntityWithHealth("heat-interface", name, Merge( + { + heat_buffer = Baseless.Data.HeatBuffer, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/HeatPipe.lua b/prototypes/constructors/Entity/EntityWithHealth/HeatPipe.lua new file mode 100644 index 0000000..893f174 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/HeatPipe.lua @@ -0,0 +1,30 @@ +local ConnectableEntityGraphics = +{ + single = Baseless.Graphics.SpriteVariations, + straight_vertical = Baseless.Graphics.SpriteVariations, + straight_horizontal = Baseless.Graphics.SpriteVariations, + corner_right_down = Baseless.Graphics.SpriteVariations, + corner_left_down = Baseless.Graphics.SpriteVariations, + corner_right_up = Baseless.Graphics.SpriteVariations, + corner_left_up = Baseless.Graphics.SpriteVariations, + t_up = Baseless.Graphics.SpriteVariations, + t_right = Baseless.Graphics.SpriteVariations, + t_down = Baseless.Graphics.SpriteVariations, + t_left = Baseless.Graphics.SpriteVariations, + ending_up = Baseless.Graphics.SpriteVariations, + ending_right = Baseless.Graphics.SpriteVariations, + ending_down = Baseless.Graphics.SpriteVariations, + ending_left = Baseless.Graphics.SpriteVariations, + cross = Baseless.Graphics.SpriteVariations, +} + +Baseless.Make.HeatPipe = function (name, prototype) + return Baseless.Make.EntityWithHealth("heat-pipe", name, Merge( + { + connection_sprites = ConnectableEntityGraphics, + heat_buffer = Baseless.Data.HeatBuffer, + heat_glow_sprites = ConnectableEntityGraphics, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Inserter.lua b/prototypes/constructors/Entity/EntityWithHealth/Inserter.lua new file mode 100644 index 0000000..20b3b57 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Inserter.lua @@ -0,0 +1,24 @@ +local InsertVector = {0, 1} +local PickupVector = {0, -1} +local CollisionBox = {{-0.1, -0.1}, {0.1, 0.1}} + +Baseless.Make.Inserter = function (name, prototype) + return Baseless.Make.EntityWithHealth("inserter", name, Merge( + { + energy_source = Baseless.Data.EnergySource.Electric, + extension_speed = 0, + hand_base_picture = Baseless.Graphics.Sprite, + hand_base_shadow = Baseless.Graphics.Sprite, + hand_closed_picture = Baseless.Graphics.Sprite, + hand_closed_shadow = Baseless.Graphics.Sprite, + hand_open_picture = Baseless.Graphics.Sprite, + hand_open_shadow = Baseless.Graphics.Sprite, + insert_position = InsertVector, + pickup_position = PickupVector, + platform_picture = Baseless.Graphics.Sprite4Way, + rotation_speed = 0, + collision_box = CollisionBox, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Lab.lua b/prototypes/constructors/Entity/EntityWithHealth/Lab.lua new file mode 100644 index 0000000..2493ec1 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Lab.lua @@ -0,0 +1,12 @@ +Baseless.Make.Lab = function (name, prototype) + return Baseless.Make.EntityWithHealth("lab", name, Merge( + { + energy_source = Baseless.Data.EnergySource.Electric, + energy_usage = Baseless.Data.Energy, + inputs = {}, + off_animation = Baseless.Graphics.Animation, + on_animation = Baseless.Graphics.Animation, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Lamp.lua b/prototypes/constructors/Entity/EntityWithHealth/Lamp.lua new file mode 100644 index 0000000..89bc367 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Lamp.lua @@ -0,0 +1,11 @@ +Baseless.Make.Lamp = function (name, prototype) + return Baseless.Make.EntityWithHealth("lamp", name, Merge( + { + energy_source = Baseless.Data.EnergySource.Electric, + energy_usage_per_tick = Baseless.Data.Energy, + picture_off = Baseless.Graphics.Sprite, + picture_on = Baseless.Graphics.Sprite, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/LandMine.lua b/prototypes/constructors/Entity/EntityWithHealth/LandMine.lua new file mode 100644 index 0000000..a5df45e --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/LandMine.lua @@ -0,0 +1,10 @@ +Baseless.Make.LandMine = function (name, prototype) + return Baseless.Make.EntityWithHealth("land-mine", name, Merge( + { + picture_safe = Baseless.Graphics.Sprite, + picture_set = Baseless.Graphics.Sprite, + trigger_radius = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Market.lua b/prototypes/constructors/Entity/EntityWithHealth/Market.lua new file mode 100644 index 0000000..aa2336a --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Market.lua @@ -0,0 +1,8 @@ +Baseless.Make.Market = function (name, prototype) + return Baseless.Make.EntityWithHealth("market", name, Merge( + { + picture = Baseless.Graphics.Sprite, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/MiningDrill.lua b/prototypes/constructors/Entity/EntityWithHealth/MiningDrill.lua new file mode 100644 index 0000000..0a50636 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/MiningDrill.lua @@ -0,0 +1,14 @@ +Baseless.Make.MiningDrill = function (name, prototype) + return Baseless.Make.EntityWithHealth("mining-drill", name, Merge( + { + animations = Baseless.Graphics.Animation4Way, + energy_source = Baseless.Data.EnergySource.Electric, + energy_usage = Baseless.Data.Energy, + mining_speed = 0, + resource_categories = {Baseless.Data.ResourceType}, + resource_searching_radius = 0, + vector_to_place_result = Baseless.Data.Vector.Zero, + }, + prototype + ), {"ResourceType"}) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/OffshorePump.lua b/prototypes/constructors/Entity/EntityWithHealth/OffshorePump.lua new file mode 100644 index 0000000..43f0269 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/OffshorePump.lua @@ -0,0 +1,11 @@ +Baseless.Make.OffshorePump = function (name, prototype) + return Baseless.Make.EntityWithHealth("offshore-pump", name, Merge( + { + picture = Baseless.Graphics.Sprite4Way, + fluid = Baseless.Data.Fluid, + fluid_box = Baseless.Data.FluidBox, + pumping_speed = 1, + }, + prototype + ), {"Fluid"}) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Pipe.lua b/prototypes/constructors/Entity/EntityWithHealth/Pipe.lua new file mode 100644 index 0000000..55daad2 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Pipe.lua @@ -0,0 +1,40 @@ +local PipePictures = +{ + straight_vertical_single = Baseless.Graphics.Sprite, + straight_vertical = Baseless.Graphics.Sprite, + straight_vertical_window = Baseless.Graphics.Sprite, + straight_horizontal = Baseless.Graphics.Sprite, + straight_horizontal_window = Baseless.Graphics.Sprite, + corner_up_right = Baseless.Graphics.Sprite, + corner_up_left = Baseless.Graphics.Sprite, + corner_down_right = Baseless.Graphics.Sprite, + corner_down_left = Baseless.Graphics.Sprite, + t_up = Baseless.Graphics.Sprite, + t_down = Baseless.Graphics.Sprite, + t_right = Baseless.Graphics.Sprite, + t_left = Baseless.Graphics.Sprite, + cross = Baseless.Graphics.Sprite, + ending_up = Baseless.Graphics.Sprite, + ending_down = Baseless.Graphics.Sprite, + ending_right = Baseless.Graphics.Sprite, + ending_left = Baseless.Graphics.Sprite, + horizontal_window_background = Baseless.Graphics.Sprite, + vertical_window_background = Baseless.Graphics.Sprite, + fluid_background = Baseless.Graphics.Sprite, + low_temperature_flow = Baseless.Graphics.Sprite, + middle_temperature_flow = Baseless.Graphics.Sprite, + high_temperature_flow = Baseless.Graphics.Sprite, + gas_flow = Baseless.Graphics.Animation, +} + +Baseless.Make.Pipe = function (type, name, prototype, conditions) + return Baseless.Make.EntityWithHealth(type or "pipe", name, Merge( + { + fluid_box = Baseless.Data.FluidBox, + horizontal_window_bounding_box = Baseless.Data.BoundingBox, + pictures = PipePictures, + vertical_window_bounding_box = Baseless.Data.BoundingBox, + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Pipe/InfinityPipe.lua b/prototypes/constructors/Entity/EntityWithHealth/Pipe/InfinityPipe.lua new file mode 100644 index 0000000..c2b68ab --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Pipe/InfinityPipe.lua @@ -0,0 +1,7 @@ +Baseless.Make.InfinityPipe = function (name, prototype) + return Baseless.Make.Pipe("infinity-pipe", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/PipeToGround.lua b/prototypes/constructors/Entity/EntityWithHealth/PipeToGround.lua new file mode 100644 index 0000000..40fa3a7 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/PipeToGround.lua @@ -0,0 +1,15 @@ +Baseless.Make.PipeToGround = function (name, prototype) + return Baseless.Make.EntityWithHealth("pipe-to-ground", name, Merge( + { + fluid_box = Baseless.Data.FluidBox, + pictures = + { + down = Baseless.Graphics.Sprite, + up = Baseless.Graphics.Sprite, + left = Baseless.Graphics.Sprite, + right = Baseless.Graphics.Sprite, + }, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/PlayerPort.lua b/prototypes/constructors/Entity/EntityWithHealth/PlayerPort.lua new file mode 100644 index 0000000..afe2f14 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/PlayerPort.lua @@ -0,0 +1,8 @@ +Baseless.Make.PlayerPort = function (name, prototype) + return Baseless.Make.EntityWithHealth("player-port", name, Merge( + { + animation = Baseless.Graphics.Animation, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/PowerSwitch.lua b/prototypes/constructors/Entity/EntityWithHealth/PowerSwitch.lua new file mode 100644 index 0000000..217c937 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/PowerSwitch.lua @@ -0,0 +1,22 @@ +local WireConnectionPoint = +{ + wire = {}, + shadow = {} +} + +Baseless.Make.PowerSwitch = function (name, prototype) + return Baseless.Make.EntityWithHealth("power-switch", name, Merge( + { + circuit_wire_connection_point = WireConnectionPoint, + led_off = Baseless.Graphics.Sprite, + led_on = Baseless.Graphics.Sprite, + left_wire_connection_point = WireConnectionPoint, + overlay_loop = Baseless.Graphics.Animation, + overlay_start = Baseless.Graphics.Animation, + overlay_start_delay = 0, + power_on_animation = Baseless.Graphics.Animation, + right_wire_connection_point = WireConnectionPoint, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/ProgrammableSpeaker.lua b/prototypes/constructors/Entity/EntityWithHealth/ProgrammableSpeaker.lua new file mode 100644 index 0000000..a99c756 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/ProgrammableSpeaker.lua @@ -0,0 +1,12 @@ +Baseless.Make.ProgrammableSpeaker = function (name, prototype) + return Baseless.Make.EntityWithHealth("programmable-speaker", name, Merge( + { + energy_source = Baseless.Data.EnergySource.Electric, + energy_usage_per_tick = Baseless.Data.Energy, + instruments = {}, + maximum_polyphony = 0, + sprite = Baseless.Graphics.Sprite, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Pump.lua b/prototypes/constructors/Entity/EntityWithHealth/Pump.lua new file mode 100644 index 0000000..634472f --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Pump.lua @@ -0,0 +1,12 @@ +Baseless.Make.Pump = function (name, prototype) + return Baseless.Make.EntityWithHealth("pump", name, Merge( + { + animations = Baseless.Graphics.Animation4Way, + energy_source = Baseless.Data.EnergySource.Electric, + energy_usage = Baseless.Data.Energy, + fluid_box = Baseless.Data.FluidBox, + pumping_speed = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Radar.lua b/prototypes/constructors/Entity/EntityWithHealth/Radar.lua new file mode 100644 index 0000000..22da4b7 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Radar.lua @@ -0,0 +1,14 @@ +Baseless.Make.Radar = function (name, prototype) + return Baseless.Make.EntityWithHealth("radar", name, Merge( + { + energy_per_nearby_scan = Baseless.Data.Energy, + energy_per_sector = Baseless.Data.Energy, + energy_source = Baseless.Data.EnergySource.Electric, + energy_usage = Baseless.Data.Energy, + max_distance_of_nearby_sector_revealed = 0, + max_distance_of_sector_revealed = 0, + pictures = Baseless.Graphics.RotatedSprite, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Rail.lua b/prototypes/constructors/Entity/EntityWithHealth/Rail.lua new file mode 100644 index 0000000..3b8544b --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Rail.lua @@ -0,0 +1,13 @@ +Baseless.Make.Rail = function (type, name, prototype, conditions) + return Baseless.Make.EntityWithHealth(type, name, Merge( + { + pictures = Baseless.Graphics.RailPictures, + placeable_by = + { + item = "dummy-rail-planner", + count = 1, + }, + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Rail/CurvedRail.lua b/prototypes/constructors/Entity/EntityWithHealth/Rail/CurvedRail.lua new file mode 100644 index 0000000..c7f9d06 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Rail/CurvedRail.lua @@ -0,0 +1,7 @@ +Baseless.Make.CurvedRail = function (name, prototype) + return Baseless.Make.Rail("curved-rail", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Rail/StraightRail.lua b/prototypes/constructors/Entity/EntityWithHealth/Rail/StraightRail.lua new file mode 100644 index 0000000..e49e685 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Rail/StraightRail.lua @@ -0,0 +1,7 @@ +Baseless.Make.StraightRail = function (name, prototype) + return Baseless.Make.Rail("straight-rail", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/RailSignalBase.lua b/prototypes/constructors/Entity/EntityWithHealth/RailSignalBase.lua new file mode 100644 index 0000000..8fdc2fd --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/RailSignalBase.lua @@ -0,0 +1,8 @@ +Baseless.Make.RailSignalBase = function (type, name, prototype, conditions) + return Baseless.Make.EntityWithHealth(type, name, Merge( + { + animation = Baseless.Graphics.RotatedAnimation, + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/RailSignalBase/RailChainSignal.lua b/prototypes/constructors/Entity/EntityWithHealth/RailSignalBase/RailChainSignal.lua new file mode 100644 index 0000000..dd0a7fb --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/RailSignalBase/RailChainSignal.lua @@ -0,0 +1,18 @@ +Baseless.Make.RailChainSignal = function (name, prototype) + return Baseless.Make.RailSignalBase("rail-chain-signal", name, Merge( + { + selection_box_offsets = + { + Baseless.Data.Vector.Zero, + Baseless.Data.Vector.Zero, + Baseless.Data.Vector.Zero, + Baseless.Data.Vector.Zero, + Baseless.Data.Vector.Zero, + Baseless.Data.Vector.Zero, + Baseless.Data.Vector.Zero, + Baseless.Data.Vector.Zero, + }, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/RailSignalBase/RailSignal.lua b/prototypes/constructors/Entity/EntityWithHealth/RailSignalBase/RailSignal.lua new file mode 100644 index 0000000..f5ffabe --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/RailSignalBase/RailSignal.lua @@ -0,0 +1,7 @@ +Baseless.Make.RailSignal = function (name, prototype) + return Baseless.Make.RailSignalBase("rail-signal", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Reactor.lua b/prototypes/constructors/Entity/EntityWithHealth/Reactor.lua new file mode 100644 index 0000000..7bf1d57 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Reactor.lua @@ -0,0 +1,11 @@ +Baseless.Make.Reactor = function (name, prototype) + return Baseless.Make.EntityWithHealth("reactor", name, Merge( + { + consumption = Baseless.Data.Energy, + energy_source = Baseless.Data.EnergySource.Electric, + heat_buffer = Baseless.Data.HeatBuffer, + working_light_picture = Baseless.Graphics.Sprite, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Roboport.lua b/prototypes/constructors/Entity/EntityWithHealth/Roboport.lua new file mode 100644 index 0000000..3569bba --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Roboport.lua @@ -0,0 +1,24 @@ +Baseless.Make.Roboport = function (name, prototype) + return Baseless.Make.EntityWithHealth("roboport", name, Merge( + { + base = Baseless.Graphics.Sprite, + base_animation = Baseless.Graphics.Animation, + base_patch = Baseless.Graphics.Sprite, + charge_approach_distance = 0, + charging_energy = Baseless.Data.Energy, + construction_radius = 0, + door_animation_down = Baseless.Graphics.Animation, + door_animation_up = Baseless.Graphics.Animation, + energy_source = Baseless.Data.EnergySource.Electric, + energy_usage = Baseless.Data.Energy, + logistics_radius = 0, + material_slots_count = 0, + recharge_minimum = Baseless.Data.Energy, + recharging_animation = Baseless.Graphics.Animation, + request_to_open_door_timeout = 0, + robot_slots_count = 0, + spawn_and_station_height = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/SimpleEntity.lua b/prototypes/constructors/Entity/EntityWithHealth/SimpleEntity.lua new file mode 100644 index 0000000..fe7f7a5 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/SimpleEntity.lua @@ -0,0 +1,8 @@ +Baseless.Make.SimpleEntity = function (name, prototype) + return Baseless.Make.EntityWithHealth("simple-entity", name, Merge( + { + picture = Baseless.Graphics.Sprite, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/SimpleEntityWithForce.lua b/prototypes/constructors/Entity/EntityWithHealth/SimpleEntityWithForce.lua new file mode 100644 index 0000000..3f51102 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/SimpleEntityWithForce.lua @@ -0,0 +1,8 @@ +Baseless.Make.SimpleEntityWithForce = function (name, prototype) + return Baseless.Make.EntityWithHealth("simple-entity-with-force", name, Merge( + { + picture = Baseless.Graphics.Sprite, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/SimpleEntityWithOwner.lua b/prototypes/constructors/Entity/EntityWithHealth/SimpleEntityWithOwner.lua new file mode 100644 index 0000000..6052c63 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/SimpleEntityWithOwner.lua @@ -0,0 +1,8 @@ +Baseless.Make.SimpleEntityWithOwner = function (name, prototype) + return Baseless.Make.EntityWithHealth("simple-entity-with-owner", name, Merge( + { + picture = Baseless.Graphics.Sprite, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/SolarPanel.lua b/prototypes/constructors/Entity/EntityWithHealth/SolarPanel.lua new file mode 100644 index 0000000..fd6d771 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/SolarPanel.lua @@ -0,0 +1,10 @@ +Baseless.Make.SolarPanel = function (name, prototype) + return Baseless.Make.EntityWithHealth("solar-panel", name, Merge( + { + energy_source = Baseless.Data.EnergySource.Electric, + picture = Baseless.Graphics.SpriteVariations, + production = Baseless.Data.Energy, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/StorageTank.lua b/prototypes/constructors/Entity/EntityWithHealth/StorageTank.lua new file mode 100644 index 0000000..c68c852 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/StorageTank.lua @@ -0,0 +1,18 @@ +Baseless.Make.StorageTank = function (name, prototype) + return Baseless.Make.EntityWithHealth("storage-tank", name, Merge( + { + flow_length_in_ticks = 1, + fluid_box = Baseless.Data.FluidBox, + pictures = + { + picture = Baseless.Graphics.Sprite4Way, + window_background = Baseless.Graphics.Sprite, + fluid_background = Baseless.Graphics.Sprite, + flow_sprite = Baseless.Graphics.Sprite, + gas_flow = Baseless.Graphics.Animation, + }, + window_bounding_box = Baseless.Data.BoundingBox, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/TrainStop.lua b/prototypes/constructors/Entity/EntityWithHealth/TrainStop.lua new file mode 100644 index 0000000..aea61ec --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/TrainStop.lua @@ -0,0 +1,8 @@ +Baseless.Make.TrainStop = function (name, prototype) + return Baseless.Make.EntityWithHealth("train-stop", name, Merge( + { + animation_ticks_per_frame = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/TransportBeltConnectable.lua b/prototypes/constructors/Entity/EntityWithHealth/TransportBeltConnectable.lua new file mode 100644 index 0000000..15586af --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/TransportBeltConnectable.lua @@ -0,0 +1,37 @@ +local AnimationSet = +{ + animation_set = Baseless.Graphics.RotatedAnimation, + east_index = 1, + west_index = 1, + north_index = 1, + south_index = 1, + starting_south_index = 1, + ending_south_index = 1, + starting_west_index = 1, + ending_west_index = 1, + starting_north_index = 1, + ending_north_index = 1, + starting_east_index = 1, + ending_east_index = 1, + + -- For TransportBelt + east_to_north_index = 1, + north_to_east_index = 1, + west_to_north_index = 1, + north_to_west_index = 1, + south_to_east_index = 1, + east_to_south_index = 1, + south_to_west_index = 1, + west_to_south_index = 1, +} + +Baseless.Make.TransportBeltConnectable = function (type, name, prototype, conditions) + return Baseless.Make.EntityWithHealth(type, name, Merge( + { + speed = 0, + belt_animation_set = AnimationSet, + collision_box = Baseless.Data.BoundingBox, + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/TransportBeltConnectable/Loader1x1.lua b/prototypes/constructors/Entity/EntityWithHealth/TransportBeltConnectable/Loader1x1.lua new file mode 100644 index 0000000..f505c06 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/TransportBeltConnectable/Loader1x1.lua @@ -0,0 +1,13 @@ +Baseless.Make.Loader1x1 = function (name, prototype) + return Baseless.Make.TransportBeltConnectable("loader-1x1", name, Merge( + { + filter_count = 0, + structure = + { + direction_in = Baseless.Graphics.Sprite4Way, + direction_out = Baseless.Graphics.Sprite4Way, + }, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/TransportBeltConnectable/Loader1x2.lua b/prototypes/constructors/Entity/EntityWithHealth/TransportBeltConnectable/Loader1x2.lua new file mode 100644 index 0000000..343bb5f --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/TransportBeltConnectable/Loader1x2.lua @@ -0,0 +1,13 @@ +Baseless.Make.Loader1x2 = function (name, prototype) + return Baseless.Make.TransportBeltConnectable("loader", name, Merge( + { + filter_count = 0, + structure = + { + direction_in = Baseless.Graphics.Sprite4Way, + direction_out = Baseless.Graphics.Sprite4Way, + }, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/TransportBeltConnectable/Splitter.lua b/prototypes/constructors/Entity/EntityWithHealth/TransportBeltConnectable/Splitter.lua new file mode 100644 index 0000000..d91f4f3 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/TransportBeltConnectable/Splitter.lua @@ -0,0 +1,8 @@ +Baseless.Make.Splitter = function (name, prototype) + return Baseless.Make.TransportBeltConnectable("splitter", name, Merge( + { + structure = Baseless.Graphics.Animation4Way, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/TransportBeltConnectable/TransportBelt.lua b/prototypes/constructors/Entity/EntityWithHealth/TransportBeltConnectable/TransportBelt.lua new file mode 100644 index 0000000..8ff25ff --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/TransportBeltConnectable/TransportBelt.lua @@ -0,0 +1,44 @@ +local AnimationVariations = +{ + sheet = Merge( + Baseless.Graphics.Animation32, + { + variation_count = 7, + } + ), +} + +local TransportBeltConnectorFrame = +{ + frame_main = AnimationVariations, + frame_shadow = AnimationVariations, + frame_main_scanner = Baseless.Graphics.Animation, + frame_main_scanner_movement_speed = 0, + frame_main_scanner_horizontal_start_shift = Baseless.Data.Vector.Zero, + frame_main_scanner_horizontal_end_shift = Baseless.Data.Vector.Zero, + frame_main_scanner_horizontal_y_scale = 0, + frame_main_scanner_horizontal_rotation = 0, + frame_main_scanner_vertical_start_shift = Baseless.Data.Vector.Zero, + frame_main_scanner_vertical_end_shift = Baseless.Data.Vector.Zero, + frame_main_scanner_vertical_y_scale = 0, + frame_main_scanner_vertical_rotation = 0, + frame_main_scanner_cross_horizontal_start_shift = Baseless.Data.Vector.Zero, + frame_main_scanner_cross_horizontal_end_shift = Baseless.Data.Vector.Zero, + frame_main_scanner_cross_horizontal_y_scale = 0, + frame_main_scanner_cross_horizontal_rotation = 0, + frame_main_scanner_cross_vertical_start_shift = Baseless.Data.Vector.Zero, + frame_main_scanner_cross_vertical_end_shift = Baseless.Data.Vector.Zero, + frame_main_scanner_cross_vertical_y_scale = 0, + frame_main_scanner_cross_vertical_rotation = 0, + frame_main_scanner_nw_ne = Baseless.Graphics.Animation, + frame_main_scanner_sw_se = Baseless.Graphics.Animation, +} + +Baseless.Make.TransportBelt = function (name, prototype) + return Baseless.Make.TransportBeltConnectable("transport-belt", name, Merge( + { + connector_frame_sprites = TransportBeltConnectorFrame, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/TransportBeltConnectable/UndergroundBelt.lua b/prototypes/constructors/Entity/EntityWithHealth/TransportBeltConnectable/UndergroundBelt.lua new file mode 100644 index 0000000..542c26b --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/TransportBeltConnectable/UndergroundBelt.lua @@ -0,0 +1,14 @@ +Baseless.Make.UndergroundBelt = function (name, prototype) + return Baseless.Make.TransportBeltConnectable("underground-belt", name, Merge( + { + max_distance = 0, + structure = + { + direction_in = Baseless.Graphics.Sprite4Way, + direction_out = Baseless.Graphics.Sprite4Way, + }, + underground_sprite = Baseless.Graphics.Sprite, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Tree.lua b/prototypes/constructors/Entity/EntityWithHealth/Tree.lua new file mode 100644 index 0000000..b455495 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Tree.lua @@ -0,0 +1,8 @@ +Baseless.Make.Tree = function (name, prototype) + return Baseless.Make.EntityWithHealth("tree", name, Merge( + { + pictures = Baseless.Graphics.SpriteVariations, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Turret.lua b/prototypes/constructors/Entity/EntityWithHealth/Turret.lua new file mode 100644 index 0000000..3b7fd77 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Turret.lua @@ -0,0 +1,10 @@ +Baseless.Make.Turret = function (type, name, prototype, conditions) + return Baseless.Make.EntityWithHealth(type or "turret", name, Merge( + { + attack_parameters = Baseless.Data.AttackParameters, + call_for_help_radius = 0, + folded_animation = Baseless.Graphics.RotatedAnimation4Way, + }, + prototype + ), Append({"AmmoType"}, conditions)) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Turret/AmmoTurret.lua b/prototypes/constructors/Entity/EntityWithHealth/Turret/AmmoTurret.lua new file mode 100644 index 0000000..9b2456b --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Turret/AmmoTurret.lua @@ -0,0 +1,9 @@ +Baseless.Make.AmmoTurret = function (name, prototype) + return Baseless.Make.Turret("ammo-turret", name, Merge( + { + automated_ammo_count = 0, + inventory_size = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Turret/ElectricTurret.lua b/prototypes/constructors/Entity/EntityWithHealth/Turret/ElectricTurret.lua new file mode 100644 index 0000000..ba7df24 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Turret/ElectricTurret.lua @@ -0,0 +1,8 @@ +Baseless.Make.ElectricTurret = function (name, prototype) + return Baseless.Make.Turret("electric-turret", name, Merge( + { + energy_source = Baseless.Data.EnergySource.Electric, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Turret/FluidTurret.lua b/prototypes/constructors/Entity/EntityWithHealth/Turret/FluidTurret.lua new file mode 100644 index 0000000..b5608ed --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Turret/FluidTurret.lua @@ -0,0 +1,12 @@ +Baseless.Make.FluidTurret = function (name, prototype) + return Baseless.Make.Turret("fluid-turret", name, Merge( + { + activation_buffer_ratio = 0, + fluid_box = Baseless.Data.FluidBox, + fluid_buffer_input_flow = 0, + fluid_buffer_size = 0, + turret_base_has_direction = true, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Unit.lua b/prototypes/constructors/Entity/EntityWithHealth/Unit.lua new file mode 100644 index 0000000..04ca559 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Unit.lua @@ -0,0 +1,19 @@ +Baseless.Make.Unit = function (name, prototype) + return Baseless.Make.EntityWithHealth("unit", name, Merge( + { + attack_parameters = Merge( + Baseless.Data.AttackParameters, + { + animation = Baseless.Graphics.RotatedAnimation, + } + ), + distance_per_frame = 0, + distraction_cooldown = 0, + movement_speed = 0, + pollution_to_join_attack = 0, + run_animation = Baseless.Graphics.RotatedAnimation, + vision_distance = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Vehicle.lua b/prototypes/constructors/Entity/EntityWithHealth/Vehicle.lua new file mode 100644 index 0000000..272aa91 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Vehicle.lua @@ -0,0 +1,11 @@ +Baseless.Make.Vehicle = function (type, name, prototype, conditions) + return Baseless.Make.EntityWithHealth(type, name, Merge( + { + braking_power = Baseless.Data.Energy, + energy_per_hit_point = 0, + friction = 1, + weight = 1, + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Vehicle/Car.lua b/prototypes/constructors/Entity/EntityWithHealth/Vehicle/Car.lua new file mode 100644 index 0000000..90f4035 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Vehicle/Car.lua @@ -0,0 +1,13 @@ +Baseless.Make.Car = function (name, prototype) + return Baseless.Make.Vehicle("car", name, Merge( + { + animation = Baseless.Graphics.RotatedAnimation, + energy_source = Baseless.Data.EnergySource.Burner, + consumption = Baseless.Data.Energy, + effectivity = 0, + inventory_size = 0, + rotation_speed = 0, + }, + prototype + ), {"FuelType"}) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Vehicle/RollingStock.lua b/prototypes/constructors/Entity/EntityWithHealth/Vehicle/RollingStock.lua new file mode 100644 index 0000000..6375a1f --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Vehicle/RollingStock.lua @@ -0,0 +1,17 @@ +local JointDistance = 2 +local CollisionBox = {{-0.1, -2}, {0.1, 2}} + +Baseless.Make.RollingStock = function (type, name, prototype, conditions) + return Baseless.Make.Vehicle(type, name, Merge( + { + air_resistance = 0, + connection_distance = 0, + joint_distance = JointDistance, + max_speed = 0, + pictures = Baseless.Graphics.RotatedSprite, + vertical_selection_shift = 0, + collision_box = CollisionBox, + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Vehicle/RollingStock/ArtilleryWagon.lua b/prototypes/constructors/Entity/EntityWithHealth/Vehicle/RollingStock/ArtilleryWagon.lua new file mode 100644 index 0000000..eb0e86d --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Vehicle/RollingStock/ArtilleryWagon.lua @@ -0,0 +1,12 @@ +Baseless.Make.ArtilleryWagon = function (name, prototype) + return Baseless.Make.RollingStock("artillery-wagon", name, Merge( + { + ammo_stack_limit = 1, + gun = Baseless.Data.GunItem, + inventory_size = 1, + manual_range_modifier = 1, + turret_rotation_speed = 0, + }, + prototype + ), {"GunItem"}) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Vehicle/RollingStock/CargoWagon.lua b/prototypes/constructors/Entity/EntityWithHealth/Vehicle/RollingStock/CargoWagon.lua new file mode 100644 index 0000000..3d91f83 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Vehicle/RollingStock/CargoWagon.lua @@ -0,0 +1,8 @@ +Baseless.Make.CargoWagon = function (name, prototype) + return Baseless.Make.RollingStock("cargo-wagon", name, Merge( + { + inventory_size = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Vehicle/RollingStock/FluidWagon.lua b/prototypes/constructors/Entity/EntityWithHealth/Vehicle/RollingStock/FluidWagon.lua new file mode 100644 index 0000000..7c77c55 --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Vehicle/RollingStock/FluidWagon.lua @@ -0,0 +1,8 @@ +Baseless.Make.FluidWagon = function (name, prototype) + return Baseless.Make.RollingStock("fluid-wagon", name, Merge( + { + capacity = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Vehicle/RollingStock/Locomotive.lua b/prototypes/constructors/Entity/EntityWithHealth/Vehicle/RollingStock/Locomotive.lua new file mode 100644 index 0000000..39c5abd --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Vehicle/RollingStock/Locomotive.lua @@ -0,0 +1,10 @@ +Baseless.Make.Locomotive = function (name, prototype) + return Baseless.Make.RollingStock("locomotive", name, Merge( + { + energy_source = Baseless.Data.EnergySource.Burner, + max_power = Baseless.Data.Energy, + reversing_power_modifier = 0, + }, + prototype + ), {"FuelType"}) +end diff --git a/prototypes/constructors/Entity/EntityWithHealth/Wall.lua b/prototypes/constructors/Entity/EntityWithHealth/Wall.lua new file mode 100644 index 0000000..bef1b3f --- /dev/null +++ b/prototypes/constructors/Entity/EntityWithHealth/Wall.lua @@ -0,0 +1,18 @@ +Baseless.Make.Wall = function (name, prototype) + return Baseless.Make.EntityWithHealth("wall", name, Merge( + { + pictures = + { + single = Baseless.Graphics.SpriteVariations, + straight_vertical = Baseless.Graphics.SpriteVariations, + straight_horizontal = Baseless.Graphics.SpriteVariations, + corner_right_down = Baseless.Graphics.SpriteVariations, + corner_left_down = Baseless.Graphics.SpriteVariations, + t_up = Baseless.Graphics.SpriteVariations, + ending_right = Baseless.Graphics.SpriteVariations, + ending_left = Baseless.Graphics.SpriteVariations, + }, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/Explosion.lua b/prototypes/constructors/Entity/Explosion.lua new file mode 100644 index 0000000..7eefb12 --- /dev/null +++ b/prototypes/constructors/Entity/Explosion.lua @@ -0,0 +1,8 @@ +Baseless.Make.Explosion = function (type, name, prototype, conditions) + return Baseless.Make.Entity(type or "explosion", name, Merge( + { + animations = Baseless.Graphics.AnimationVariations, + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Entity/Explosion/FlameThrowerExplosion.lua b/prototypes/constructors/Entity/Explosion/FlameThrowerExplosion.lua new file mode 100644 index 0000000..07cbf0e --- /dev/null +++ b/prototypes/constructors/Entity/Explosion/FlameThrowerExplosion.lua @@ -0,0 +1,9 @@ +Baseless.Make.FlameThrowerExplosion = function (name, prototype) + return Baseless.Make.Explosion("flame-thrower-explosion", name, Merge( + { + damage = Baseless.Data.DamagePrototype, + slow_down_factor = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/FireFlame.lua b/prototypes/constructors/Entity/FireFlame.lua new file mode 100644 index 0000000..ea8e25a --- /dev/null +++ b/prototypes/constructors/Entity/FireFlame.lua @@ -0,0 +1,10 @@ +Baseless.Make.FireFlame = function (name, prototype) + return Baseless.Make.Entity("fire", name, Merge( + { + damage_per_tick = Baseless.Data.DamagePrototype, + spread_delay = 0, + spread_delay_deviation = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/FluidStream.lua b/prototypes/constructors/Entity/FluidStream.lua new file mode 100644 index 0000000..41d85c3 --- /dev/null +++ b/prototypes/constructors/Entity/FluidStream.lua @@ -0,0 +1,11 @@ +Baseless.Make.FluidStream = function (name, prototype) + return Baseless.Make.Entity("stream", name, Merge( + { + particle_horizontal_speed = 1, + particle_horizontal_speed_deviation = 0, + particle_spawn_interval = 0, + particle_vertical_acceleration = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/FlyingText.lua b/prototypes/constructors/Entity/FlyingText.lua new file mode 100644 index 0000000..0435ec3 --- /dev/null +++ b/prototypes/constructors/Entity/FlyingText.lua @@ -0,0 +1,9 @@ +Baseless.Make.FlyingText = function (name, prototype) + return Baseless.Make.Entity("flying-text", name, Merge( + { + speed = 0, + time_to_live = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/HighlightBoxEntity.lua b/prototypes/constructors/Entity/HighlightBoxEntity.lua new file mode 100644 index 0000000..5ea4cc3 --- /dev/null +++ b/prototypes/constructors/Entity/HighlightBoxEntity.lua @@ -0,0 +1,7 @@ +Baseless.Make.HighlightBoxEntity = function (name, prototype) + return Baseless.Make.Entity("highlight-box", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/ItemEntity.lua b/prototypes/constructors/Entity/ItemEntity.lua new file mode 100644 index 0000000..c9e5d47 --- /dev/null +++ b/prototypes/constructors/Entity/ItemEntity.lua @@ -0,0 +1,7 @@ +Baseless.Make.ItemEntity = function (name, prototype) + return Baseless.Make.Entity("item-entity", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/ItemRequestProxy.lua b/prototypes/constructors/Entity/ItemRequestProxy.lua new file mode 100644 index 0000000..230caff --- /dev/null +++ b/prototypes/constructors/Entity/ItemRequestProxy.lua @@ -0,0 +1,8 @@ +Baseless.Make.ItemRequestProxy = function (name, prototype) + return Baseless.Make.Entity("item-request-proxy", name, Merge( + { + picture = Baseless.Graphics.Sprite, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/ParticleSource.lua b/prototypes/constructors/Entity/ParticleSource.lua new file mode 100644 index 0000000..1b40b77 --- /dev/null +++ b/prototypes/constructors/Entity/ParticleSource.lua @@ -0,0 +1,13 @@ +Baseless.Make.ParticleSource = function (name, prototype) + return Baseless.Make.Entity("particle-source", name, Merge( + { + height = 0, + horizontal_speed = 0, + particle = Baseless.Data.Particle, + time_before_start = 0, + time_to_live = 0, + vertical_speed = 0, + }, + prototype + ), {"Particle"}) +end diff --git a/prototypes/constructors/Entity/Projectile.lua b/prototypes/constructors/Entity/Projectile.lua new file mode 100644 index 0000000..8fecb43 --- /dev/null +++ b/prototypes/constructors/Entity/Projectile.lua @@ -0,0 +1,9 @@ +Baseless.Make.Projectile = function (name, prototype) + return Baseless.Make.Entity("projectile", name, Merge( + { + acceleration = 0, + animation = Baseless.Graphics.Animation, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/ResourceEntity.lua b/prototypes/constructors/Entity/ResourceEntity.lua new file mode 100644 index 0000000..290e63d --- /dev/null +++ b/prototypes/constructors/Entity/ResourceEntity.lua @@ -0,0 +1,10 @@ +Baseless.Make.ResourceEntity = function (name, prototype) + return Baseless.Make.Entity("resource", name, Merge( + { + stage_counts = {0}, + stages = Baseless.Graphics.AnimationVariations, + minable = Baseless.Data.MinableProperties, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/RocketSiloRocket.lua b/prototypes/constructors/Entity/RocketSiloRocket.lua new file mode 100644 index 0000000..1aa06c1 --- /dev/null +++ b/prototypes/constructors/Entity/RocketSiloRocket.lua @@ -0,0 +1,34 @@ +Baseless.Make.RocketSiloRocket = function (name, prototype) + return Baseless.Make.Entity("rocket-silo-rocket", name, Merge( + { + effects_fade_in_end_distance = 0, + effects_fade_in_start_distance = 0, + engine_starting_speed = 0, + flying_acceleration = 0, + flying_speed = 0, + full_render_layer_switch_distance = 0, + inventory_size = 0, + rising_speed = 0, + rocket_flame_animation = Baseless.Graphics.Animation, + rocket_flame_left_animation = Baseless.Graphics.Animation, + rocket_flame_left_rotation = 0, + rocket_flame_right_animation = Baseless.Graphics.Animation, + rocket_flame_right_rotation = 0, + rocket_glare_overlay_sprite = Baseless.Graphics.Sprite, + rocket_launch_offset = Baseless.Data.Vector.Zero, + rocket_render_layer_switch_distance = 0, + rocket_rise_offset = Baseless.Data.Vector.Zero, + rocket_shadow_sprite = Baseless.Graphics.Sprite, + rocket_smoke_bottom1_animation = Baseless.Graphics.Animation, + rocket_smoke_bottom2_animation = Baseless.Graphics.Animation, + rocket_smoke_top1_animation = Baseless.Graphics.Animation, + rocket_smoke_top2_animation = Baseless.Graphics.Animation, + rocket_smoke_top3_animation = Baseless.Graphics.Animation, + rocket_sprite = Baseless.Graphics.Sprite, + rocket_visible_distance_from_center = 0, + shadow_fade_out_end_ratio = 0, + shadow_fade_out_start_ratio = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/RocketSiloRocketShadow.lua b/prototypes/constructors/Entity/RocketSiloRocketShadow.lua new file mode 100644 index 0000000..cdfd5ce --- /dev/null +++ b/prototypes/constructors/Entity/RocketSiloRocketShadow.lua @@ -0,0 +1,7 @@ +Baseless.Make.RocketSiloRocketShadow = function (name, prototype) + return Baseless.Make.Entity("rocket-silo-rocket-shadow", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/Smoke.lua b/prototypes/constructors/Entity/Smoke.lua new file mode 100644 index 0000000..9da16c4 --- /dev/null +++ b/prototypes/constructors/Entity/Smoke.lua @@ -0,0 +1,8 @@ +Baseless.Make.Smoke = function (type, name, prototype, conditions) + return Baseless.Make.Entity(type, name, Merge( + { + animation = Baseless.Graphics.Animation, + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Entity/Smoke/SmokeWithTrigger.lua b/prototypes/constructors/Entity/Smoke/SmokeWithTrigger.lua new file mode 100644 index 0000000..56b4b2b --- /dev/null +++ b/prototypes/constructors/Entity/Smoke/SmokeWithTrigger.lua @@ -0,0 +1,7 @@ +Baseless.Make.SmokeWithTrigger = function (name, prototype) + return Baseless.Make.Smoke("smoke-with-trigger", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/SpeechBubble.lua b/prototypes/constructors/Entity/SpeechBubble.lua new file mode 100644 index 0000000..b253c04 --- /dev/null +++ b/prototypes/constructors/Entity/SpeechBubble.lua @@ -0,0 +1,8 @@ +Baseless.Make.SpeechBubble = function (name, prototype) + return Baseless.Make.Entity("speech-bubble", name, Merge( + { + style = Baseless.Data.SpeechBubbleStyle, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/Sticker.lua b/prototypes/constructors/Entity/Sticker.lua new file mode 100644 index 0000000..07f19a4 --- /dev/null +++ b/prototypes/constructors/Entity/Sticker.lua @@ -0,0 +1,8 @@ +Baseless.Make.Sticker = function (name, prototype) + return Baseless.Make.Entity("sticker", name, Merge( + { + duration_in_ticks = 1, + }, + prototype + )) +end diff --git a/prototypes/constructors/Entity/TileGhost.lua b/prototypes/constructors/Entity/TileGhost.lua new file mode 100644 index 0000000..3bbc4d3 --- /dev/null +++ b/prototypes/constructors/Entity/TileGhost.lua @@ -0,0 +1,7 @@ +Baseless.Make.TileGhost = function (name, prototype) + return Baseless.Make.Entity("tile-ghost", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Equipment.lua b/prototypes/constructors/Equipment.lua new file mode 100644 index 0000000..38dae58 --- /dev/null +++ b/prototypes/constructors/Equipment.lua @@ -0,0 +1,11 @@ +Baseless.Make.Equipment = function (type, name, prototype, conditions) + return Baseless.Make.Base(type, name, Merge( + { + categories = {Baseless.Data.EquipmentType}, + energy_source = Baseless.Data.EnergySource.Electric, + shape = Baseless.Data.EquipmentShape, + sprite = Baseless.Graphics.Sprite, + }, + prototype + ), Append({"EquipmentType"}, conditions or {})) +end diff --git a/prototypes/constructors/Equipment/ActiveDefenseEquipment.lua b/prototypes/constructors/Equipment/ActiveDefenseEquipment.lua new file mode 100644 index 0000000..269440a --- /dev/null +++ b/prototypes/constructors/Equipment/ActiveDefenseEquipment.lua @@ -0,0 +1,9 @@ +Baseless.Make.ActiveDefenseEquipment = function (name, prototype) + return Baseless.Make.Equipment("active-defense-equipment", name, Merge( + { + attack_parameters = Baseless.Data.AttackParameters, + automatic = true, + }, + prototype + ), {"AmmoType"}) +end diff --git a/prototypes/constructors/Equipment/BatteryEquipment.lua b/prototypes/constructors/Equipment/BatteryEquipment.lua new file mode 100644 index 0000000..88f5691 --- /dev/null +++ b/prototypes/constructors/Equipment/BatteryEquipment.lua @@ -0,0 +1,7 @@ +Baseless.Make.BatteryEquipment = function (name, prototype) + return Baseless.Make.Equipment("battery-equipment", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Equipment/BeltImmunityEquipment.lua b/prototypes/constructors/Equipment/BeltImmunityEquipment.lua new file mode 100644 index 0000000..6e9598d --- /dev/null +++ b/prototypes/constructors/Equipment/BeltImmunityEquipment.lua @@ -0,0 +1,8 @@ +Baseless.Make.BeltImmunityEquipment = function (name, prototype) + return Baseless.Make.Equipment("belt-immunity-equipment", name, Merge( + { + energy_consumption = Baseless.Data.Energy, + }, + prototype + )) +end diff --git a/prototypes/constructors/Equipment/EnergyShieldEquipment.lua b/prototypes/constructors/Equipment/EnergyShieldEquipment.lua new file mode 100644 index 0000000..e718807 --- /dev/null +++ b/prototypes/constructors/Equipment/EnergyShieldEquipment.lua @@ -0,0 +1,9 @@ +Baseless.Make.EnergyShieldEquipment = function (name, prototype) + return Baseless.Make.Equipment("energy-shield-equipment", name, Merge( + { + energy_per_shield = Baseless.Data.Energy, + max_shield_value = 1, + }, + prototype + )) +end diff --git a/prototypes/constructors/Equipment/GeneratorEquipment.lua b/prototypes/constructors/Equipment/GeneratorEquipment.lua new file mode 100644 index 0000000..cc665ea --- /dev/null +++ b/prototypes/constructors/Equipment/GeneratorEquipment.lua @@ -0,0 +1,8 @@ +Baseless.Make.GeneratorEquipment = function (name, prototype) + return Baseless.Make.Equipment("generator-equipment", name, Merge( + { + power = Baseless.Data.Energy, + }, + prototype + )) +end diff --git a/prototypes/constructors/Equipment/MovementBonusEquipment.lua b/prototypes/constructors/Equipment/MovementBonusEquipment.lua new file mode 100644 index 0000000..b074667 --- /dev/null +++ b/prototypes/constructors/Equipment/MovementBonusEquipment.lua @@ -0,0 +1,9 @@ +Baseless.Make.MovementBonusEquipment = function (name, prototype) + return Baseless.Make.Equipment("movement-bonus-equipment", name, Merge( + { + energy_consumption = Baseless.Data.Energy, + movement_bonus = 1, + }, + prototype + )) +end diff --git a/prototypes/constructors/Equipment/NightVisionEquipment.lua b/prototypes/constructors/Equipment/NightVisionEquipment.lua new file mode 100644 index 0000000..4529e97 --- /dev/null +++ b/prototypes/constructors/Equipment/NightVisionEquipment.lua @@ -0,0 +1,9 @@ +Baseless.Make.NightVisionEquipment = function (name, prototype) + return Baseless.Make.Equipment("night-vision-equipment", name, Merge( + { + color_lookup = Baseless.Data.DaytimeColorLookupTable, + energy_input = Baseless.Data.Energy, + }, + prototype + )) +end diff --git a/prototypes/constructors/Equipment/RoboportEquipment.lua b/prototypes/constructors/Equipment/RoboportEquipment.lua new file mode 100644 index 0000000..7ce1f23 --- /dev/null +++ b/prototypes/constructors/Equipment/RoboportEquipment.lua @@ -0,0 +1,12 @@ +Baseless.Make.RoboportEquipment = function (name, prototype) + return Baseless.Make.Equipment("roboport-equipment", name, Merge( + { + charge_approach_distance = 0, + charging_energy = Baseless.Data.Energy, + construction_radius = 0, + recharging_animation = Baseless.Graphics.Animation, + spawn_and_station_height = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/Equipment/SolarPanelEquipment.lua b/prototypes/constructors/Equipment/SolarPanelEquipment.lua new file mode 100644 index 0000000..dbf8d3a --- /dev/null +++ b/prototypes/constructors/Equipment/SolarPanelEquipment.lua @@ -0,0 +1,8 @@ +Baseless.Make.SolarPanelEquipment = function (name, prototype) + return Baseless.Make.Equipment("solar-panel-equipment", name, Merge( + { + power = Baseless.Data.Energy, + }, + prototype + )) +end diff --git a/prototypes/constructors/EquipmentCategory.lua b/prototypes/constructors/EquipmentCategory.lua new file mode 100644 index 0000000..adcfddc --- /dev/null +++ b/prototypes/constructors/EquipmentCategory.lua @@ -0,0 +1,3 @@ +Baseless.Make.EquipmentCategory = function (name, prototype) + return Baseless.Make.Base("equipment-category", name, prototype) +end diff --git a/prototypes/constructors/EquipmentGrid.lua b/prototypes/constructors/EquipmentGrid.lua new file mode 100644 index 0000000..3db508f --- /dev/null +++ b/prototypes/constructors/EquipmentGrid.lua @@ -0,0 +1,10 @@ +Baseless.Make.EquipmentGrid = function (name, prototype) + return Baseless.Make.Base("equipment-grid", name, Merge( + { + equipment_categories = {Baseless.Data.EquipmentType}, + height = 0, + width = 0, + }, + prototype + ), {"EquipmentType"}) +end diff --git a/prototypes/constructors/Fluid.lua b/prototypes/constructors/Fluid.lua new file mode 100644 index 0000000..f4d0f39 --- /dev/null +++ b/prototypes/constructors/Fluid.lua @@ -0,0 +1,13 @@ +Baseless.Make.Fluid = function (type, name, prototype, conditions) + return Baseless.Make.Base("fluid", name, Merge( + Baseless.Graphics.IconSpecification, + { + base_color = Baseless.Data.Color, + default_temperature = 0, + flow_color = Baseless.Data.Color, + max_temperature = 0, + subgroup = "other", + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/FuelCategory.lua b/prototypes/constructors/FuelCategory.lua new file mode 100644 index 0000000..7df79db --- /dev/null +++ b/prototypes/constructors/FuelCategory.lua @@ -0,0 +1,3 @@ +Baseless.Make.FuelCategory = function (name, prototype) + return Baseless.Make.Base("fuel-category", name, prototype) +end diff --git a/prototypes/constructors/Item.lua b/prototypes/constructors/Item.lua new file mode 100644 index 0000000..bf57ab2 --- /dev/null +++ b/prototypes/constructors/Item.lua @@ -0,0 +1,9 @@ +Baseless.Make.Item = function (type, name, prototype, conditions) + return Baseless.Make.Base(type or "item", name, Merge( + Baseless.Graphics.IconSpecification, + { + stack_size = 1, + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Item/Ammo.lua b/prototypes/constructors/Item/Ammo.lua new file mode 100644 index 0000000..c0ef1a6 --- /dev/null +++ b/prototypes/constructors/Item/Ammo.lua @@ -0,0 +1,8 @@ +Baseless.Make.Ammo = function (name, prototype) + return Baseless.Make.Item("ammo", name, Merge( + { + ammo_type = Baseless.Data.AmmoType, + }, + prototype + ), {"AmmoType"}) +end diff --git a/prototypes/constructors/Item/Capsule.lua b/prototypes/constructors/Item/Capsule.lua new file mode 100644 index 0000000..db7d382 --- /dev/null +++ b/prototypes/constructors/Item/Capsule.lua @@ -0,0 +1,12 @@ +Baseless.Make.Capsule = function (name, prototype) + return Baseless.Make.Item("capsule", name, Merge( + { + capsule_action = + { + type = "throw", + attack_parameters = Baseless.Data.AttackParameters, + }, + }, + prototype + ), {"AmmoType"}) +end diff --git a/prototypes/constructors/Item/Gun.lua b/prototypes/constructors/Item/Gun.lua new file mode 100644 index 0000000..b71f4c4 --- /dev/null +++ b/prototypes/constructors/Item/Gun.lua @@ -0,0 +1,8 @@ +Baseless.Make.Gun = function (name, prototype) + return Baseless.Make.Item("gun", name, Merge( + { + attack_parameters = Baseless.Data.AttackParameters, + }, + prototype + ), {"AmmoType"}) +end diff --git a/prototypes/constructors/Item/ItemWithEntityData.lua b/prototypes/constructors/Item/ItemWithEntityData.lua new file mode 100644 index 0000000..1930b12 --- /dev/null +++ b/prototypes/constructors/Item/ItemWithEntityData.lua @@ -0,0 +1,7 @@ +Baseless.Make.ItemWithEntityData = function (name, prototype) + return Baseless.Make.Item("item-with-entity-data", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Item/ItemWithLabel.lua b/prototypes/constructors/Item/ItemWithLabel.lua new file mode 100644 index 0000000..799b939 --- /dev/null +++ b/prototypes/constructors/Item/ItemWithLabel.lua @@ -0,0 +1,7 @@ +Baseless.Make.ItemWithLabel = function (type, name, prototype, conditions) + return Baseless.Make.Item(type or "item-with-label", name, Merge( + { + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Item/ItemWithLabel/ItemWithInventory.lua b/prototypes/constructors/Item/ItemWithLabel/ItemWithInventory.lua new file mode 100644 index 0000000..dda639c --- /dev/null +++ b/prototypes/constructors/Item/ItemWithLabel/ItemWithInventory.lua @@ -0,0 +1,8 @@ +Baseless.Make.ItemWithInventory = function (type, name, prototype, conditions) + return Baseless.Make.ItemWithLabel(type or "item-with-inventory", name, Merge( + { + inventory_size = 0, + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Item/ItemWithLabel/ItemWithInventory/BlueprintBook.lua b/prototypes/constructors/Item/ItemWithLabel/ItemWithInventory/BlueprintBook.lua new file mode 100644 index 0000000..e140f27 --- /dev/null +++ b/prototypes/constructors/Item/ItemWithLabel/ItemWithInventory/BlueprintBook.lua @@ -0,0 +1,7 @@ +Baseless.Make.BlueprintBook = function (name, prototype) + return Baseless.Make.ItemWithInventory("blueprint-book", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Item/ItemWithLabel/ItemWithTags.lua b/prototypes/constructors/Item/ItemWithLabel/ItemWithTags.lua new file mode 100644 index 0000000..1c3633d --- /dev/null +++ b/prototypes/constructors/Item/ItemWithLabel/ItemWithTags.lua @@ -0,0 +1,7 @@ +Baseless.Make.ItemWithTags = function (name, prototype) + return Baseless.Make.ItemWithLabel("item-with-tags", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Item/ItemWithLabel/SelectionTool.lua b/prototypes/constructors/Item/ItemWithLabel/SelectionTool.lua new file mode 100644 index 0000000..479b3c3 --- /dev/null +++ b/prototypes/constructors/Item/ItemWithLabel/SelectionTool.lua @@ -0,0 +1,13 @@ +Baseless.Make.SelectionTool = function (type, name, prototype, conditions) + return Baseless.Make.ItemWithLabel(type or "selection-tool", name, Merge( + { + alt_selection_color = Baseless.Data.Color, + alt_selection_cursor_box_type = Baseless.Data.SelectionType, + alt_selection_mode = Baseless.Data.SelectionMode, + selection_color = Baseless.Data.Color, + selection_cursor_box_type = Baseless.Data.SelectionType, + selection_mode = Baseless.Data.SelectionMode, + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Item/ItemWithLabel/SelectionTool/Blueprint.lua b/prototypes/constructors/Item/ItemWithLabel/SelectionTool/Blueprint.lua new file mode 100644 index 0000000..217288b --- /dev/null +++ b/prototypes/constructors/Item/ItemWithLabel/SelectionTool/Blueprint.lua @@ -0,0 +1,7 @@ +Baseless.Make.Blueprint = function (name, prototype) + return Baseless.Make.SelectionTool("blueprint", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Item/ItemWithLabel/SelectionTool/CopyPasteTool.lua b/prototypes/constructors/Item/ItemWithLabel/SelectionTool/CopyPasteTool.lua new file mode 100644 index 0000000..e241b0b --- /dev/null +++ b/prototypes/constructors/Item/ItemWithLabel/SelectionTool/CopyPasteTool.lua @@ -0,0 +1,7 @@ +Baseless.Make.CopyPasteTool = function (name, prototype) + return Baseless.Make.SelectionTool("copy-paste-tool", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Item/ItemWithLabel/SelectionTool/DeconstructionItem.lua b/prototypes/constructors/Item/ItemWithLabel/SelectionTool/DeconstructionItem.lua new file mode 100644 index 0000000..28effa6 --- /dev/null +++ b/prototypes/constructors/Item/ItemWithLabel/SelectionTool/DeconstructionItem.lua @@ -0,0 +1,7 @@ +Baseless.Make.DeconstructionItem = function (name, prototype) + return Baseless.Make.SelectionTool("deconstruction-item", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Item/ItemWithLabel/SelectionTool/UpgradeItem.lua b/prototypes/constructors/Item/ItemWithLabel/SelectionTool/UpgradeItem.lua new file mode 100644 index 0000000..6ed6d72 --- /dev/null +++ b/prototypes/constructors/Item/ItemWithLabel/SelectionTool/UpgradeItem.lua @@ -0,0 +1,7 @@ +Baseless.Make.UpgradeItem = function (name, prototype) + return Baseless.Make.SelectionTool("upgrade-item", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Item/Module.lua b/prototypes/constructors/Item/Module.lua new file mode 100644 index 0000000..4a0d9ff --- /dev/null +++ b/prototypes/constructors/Item/Module.lua @@ -0,0 +1,10 @@ +Baseless.Make.Module = function (name, prototype) + return Baseless.Make.Item("module", name, Merge( + { + category = Baseless.Data.ModuleType, + effect = Baseless.Data.Effect, + tier = 0, + }, + prototype + ), {"ModuleType"}) +end diff --git a/prototypes/constructors/Item/RailPlanner.lua b/prototypes/constructors/Item/RailPlanner.lua new file mode 100644 index 0000000..2e1453a --- /dev/null +++ b/prototypes/constructors/Item/RailPlanner.lua @@ -0,0 +1,9 @@ +Baseless.Make.RailPlanner = function (name, prototype) + return Baseless.Make.Item("rail-planner", name, Merge( + { + curved_rail = Baseless.Data.CurvedRailEntity, + straight_rail = Baseless.Data.StraightRailEntity, + }, + prototype + ), {"RailEntity"}) +end diff --git a/prototypes/constructors/Item/Tool.lua b/prototypes/constructors/Item/Tool.lua new file mode 100644 index 0000000..b5cfbc5 --- /dev/null +++ b/prototypes/constructors/Item/Tool.lua @@ -0,0 +1,8 @@ +Baseless.Make.Tool = function (type, name, prototype, conditions) + return Baseless.Make.Item(type or "tool", name, Merge( + { + infinite = true, + }, + prototype + ), conditions) +end diff --git a/prototypes/constructors/Item/Tool/Armor.lua b/prototypes/constructors/Item/Tool/Armor.lua new file mode 100644 index 0000000..18fd978 --- /dev/null +++ b/prototypes/constructors/Item/Tool/Armor.lua @@ -0,0 +1,7 @@ +Baseless.Make.Armor = function (name, prototype) + return Baseless.Make.Tool("armor", name, Merge( + { + }, + prototype + )) +end diff --git a/prototypes/constructors/Item/Tool/RepairTool.lua b/prototypes/constructors/Item/Tool/RepairTool.lua new file mode 100644 index 0000000..de6a5dd --- /dev/null +++ b/prototypes/constructors/Item/Tool/RepairTool.lua @@ -0,0 +1,8 @@ +Baseless.Make.RepairTool = function (name, prototype) + return Baseless.Make.Tool("repair-tool", name, Merge( + { + speed = 0, + }, + prototype + )) +end diff --git a/prototypes/constructors/ItemGroup.lua b/prototypes/constructors/ItemGroup.lua new file mode 100644 index 0000000..9f80950 --- /dev/null +++ b/prototypes/constructors/ItemGroup.lua @@ -0,0 +1,6 @@ +Baseless.Make.ItemGroup = function (name, prototype) + return Baseless.Make.Base("item-group", name, Merge( + Baseless.Graphics.IconSpecification, + prototype + )) +end diff --git a/prototypes/constructors/ItemSubGroup.lua b/prototypes/constructors/ItemSubGroup.lua new file mode 100644 index 0000000..5c3317b --- /dev/null +++ b/prototypes/constructors/ItemSubGroup.lua @@ -0,0 +1,8 @@ +Baseless.Make.ItemSubGroup = function (name, group, prototype) + return Baseless.Make.Base("item-subgroup", name, Merge( + { + group = group, + }, + prototype + )) +end diff --git a/prototypes/constructors/ModuleCategory.lua b/prototypes/constructors/ModuleCategory.lua new file mode 100644 index 0000000..0e68abf --- /dev/null +++ b/prototypes/constructors/ModuleCategory.lua @@ -0,0 +1,3 @@ +Baseless.Make.ModuleCategory = function (name, prototype) + return Baseless.Make.Base("module-category", name, prototype) +end diff --git a/prototypes/constructors/Particle.lua b/prototypes/constructors/Particle.lua new file mode 100644 index 0000000..e3b1e22 --- /dev/null +++ b/prototypes/constructors/Particle.lua @@ -0,0 +1,9 @@ +Baseless.Make.Particle = function (name, prototype) + return Baseless.Make.Base("optimized-particle", name, Merge( + { + life_time = 0, + pictures = Baseless.Graphics.AnimationVariations, + }, + prototype + )) +end diff --git a/prototypes/constructors/RecipeCategory.lua b/prototypes/constructors/RecipeCategory.lua new file mode 100644 index 0000000..7c71f62 --- /dev/null +++ b/prototypes/constructors/RecipeCategory.lua @@ -0,0 +1,3 @@ +Baseless.Make.RecipeCategory = function (name, prototype) + return Baseless.Make.Base("recipe-category", name, prototype) +end diff --git a/prototypes/constructors/ResourceCategory.lua b/prototypes/constructors/ResourceCategory.lua new file mode 100644 index 0000000..1229931 --- /dev/null +++ b/prototypes/constructors/ResourceCategory.lua @@ -0,0 +1,3 @@ +Baseless.Make.ResourceCategory = function (name, prototype) + return Baseless.Make.Base("resource-category", name, prototype) +end diff --git a/prototypes/constructors/Tile.lua b/prototypes/constructors/Tile.lua new file mode 100644 index 0000000..ebdbf17 --- /dev/null +++ b/prototypes/constructors/Tile.lua @@ -0,0 +1,12 @@ +Baseless.Make.Tile = function (name, prototype) + return Baseless.Make.Base("tile", name, Merge( + { + collision_mask = Baseless.Data.CollisionMask, + layer = 0, + map_color = Baseless.Data.Color, + pollution_absorption_per_second = 0, + variants = Baseless.Graphics.Transitions, + }, + prototype + )) +end diff --git a/prototypes/constructors/TrivialSmoke.lua b/prototypes/constructors/TrivialSmoke.lua new file mode 100644 index 0000000..ca2d441 --- /dev/null +++ b/prototypes/constructors/TrivialSmoke.lua @@ -0,0 +1,10 @@ +Baseless.Make.TrivialSmoke = function (name, prototype) + return Baseless.Make.Base("trivial-smoke", name, Merge( + { + animation = Baseless.Graphics.Animation, + duration = 1, + cyclic = 1, + }, + prototype + )) +end diff --git a/prototypes/constructors/VirtualSignal.lua b/prototypes/constructors/VirtualSignal.lua new file mode 100644 index 0000000..20642ac --- /dev/null +++ b/prototypes/constructors/VirtualSignal.lua @@ -0,0 +1,9 @@ +Baseless.Make.VirtualSignal = function (name, prototype) + return Baseless.Make.Base("virtual-signal", name, Merge( + Baseless.Graphics.IconSpecification, + { + subgroup = Baseless.Data.Group, + }, + prototype + )) +end diff --git a/prototypes/entity.lua b/prototypes/entity.lua new file mode 100644 index 0000000..3618b32 --- /dev/null +++ b/prototypes/entity.lua @@ -0,0 +1,95 @@ +Baseless.RegisterIfUnique { + Baseless.Make.Accumulator(), + Baseless.Make.AmmoTurret(), + Baseless.Make.ArithmeticCombinator(), + Baseless.Make.Arrow(), + Baseless.Make.ArtilleryFlare(), + Baseless.Make.ArtilleryProjectile(), + Baseless.Make.ArtilleryTurret(), + Baseless.Make.ArtilleryWagon(), + Baseless.Make.AssemblingMachine(), + Baseless.Make.Beacon(), + Baseless.Make.Beam(), + Baseless.Make.Boiler(), + Baseless.Make.BurnerGenerator(), + Baseless.Make.Car(), + Baseless.Make.CargoWagon(), + Baseless.Make.Character(), + Baseless.Make.CharacterCorpse(), + Baseless.Make.Cliff(), + Baseless.Make.CombatRobot(), + Baseless.Make.ConstantCombinator(), + Baseless.Make.ConstructionRobot(), + Baseless.Make.Container(), + Baseless.Make.Corpse(), + Baseless.Make.DeciderCombinator(), + Baseless.Make.DeconstructibleTileProxy(), + Baseless.Make.ElectricEnergyInterface(), + Baseless.Make.ElectricPole(), + Baseless.Make.ElectricTurret(), + Baseless.Make.EnemySpawner(), + Baseless.Make.EntityGhost(), + Baseless.Make.Explosion(), + Baseless.Make.FireFlame(), + Baseless.Make.Fish(), + Baseless.Make.FlameThrowerExplosion(), + Baseless.Make.FluidStream(), + Baseless.Make.FluidTurret(), + Baseless.Make.FluidWagon(), + Baseless.Make.FlyingText(), + Baseless.Make.Furnace(), + Baseless.Make.Gate(), + Baseless.Make.Generator(), + Baseless.Make.HeatInterface(), + Baseless.Make.HeatPipe(), + Baseless.Make.HighlightBoxEntity(), + Baseless.Make.InfinityContainer(), + Baseless.Make.InfinityPipe(), + Baseless.Make.Inserter(), + Baseless.Make.ItemEntity(), + Baseless.Make.ItemRequestProxy(), + Baseless.Make.Lab(), + Baseless.Make.Lamp(), + Baseless.Make.LandMine(), + Baseless.Make.Loader1x1(), + Baseless.Make.Loader1x2(), + Baseless.Make.Locomotive(), + Baseless.Make.LogisticContainer(), + Baseless.Make.LogisticRobot(), + Baseless.Make.Market(), + Baseless.Make.MiningDrill(), + Baseless.Make.OffshorePump(), + Baseless.Make.ParticleSource(), + Baseless.Make.Pipe(), + Baseless.Make.PipeToGround(), + Baseless.Make.PlayerPort(), + Baseless.Make.PowerSwitch(), + Baseless.Make.ProgrammableSpeaker(), + Baseless.Make.Projectile(), + Baseless.Make.Pump(), + Baseless.Make.Radar(), + Baseless.Make.RailRemnants(), + Baseless.Make.RailChainSignal(), + Baseless.Make.RailSignal(), + Baseless.Make.Reactor(), + Baseless.Make.ResourceEntity(), + Baseless.Make.Roboport(), + Baseless.Make.RocketSilo(), + Baseless.Make.RocketSiloRocketShadow(), + Baseless.Make.SimpleEntity(), + Baseless.Make.SimpleEntityWithForce(), + Baseless.Make.SimpleEntityWithOwner(), + Baseless.Make.SmokeWithTrigger(), + Baseless.Make.SolarPanel(), + Baseless.Make.SpeechBubble(), + Baseless.Make.Splitter(), + Baseless.Make.Sticker(), + Baseless.Make.StorageTank(), + Baseless.Make.TileGhost(), + Baseless.Make.TrainStop(), + Baseless.Make.TransportBelt(), + Baseless.Make.Tree(), + Baseless.Make.Turret(), + Baseless.Make.UndergroundBelt(), + Baseless.Make.Wall(), +} diff --git a/prototypes/entity/accumulator.lua b/prototypes/entity/accumulator.lua deleted file mode 100644 index 4d6ad8e..0000000 --- a/prototypes/entity/accumulator.lua +++ /dev/null @@ -1,6 +0,0 @@ -CreateEntityWithHealth("accumulator", { - charge_cooldown = 0, - discharge_cooldown = 0, - energy_source = Baseless.EnergySource.Void, - picture = Baseless.Sprite, -}) diff --git a/prototypes/entity/ammo-turret.lua b/prototypes/entity/ammo-turret.lua deleted file mode 100644 index b79199c..0000000 --- a/prototypes/entity/ammo-turret.lua +++ /dev/null @@ -1,4 +0,0 @@ -CreateTurret("ammo-turret", { - automated_ammo_count = 0, - inventory_size = 0, -}) diff --git a/prototypes/entity/arithmetic-combinator.lua b/prototypes/entity/arithmetic-combinator.lua deleted file mode 100644 index 9c05af6..0000000 --- a/prototypes/entity/arithmetic-combinator.lua +++ /dev/null @@ -1,13 +0,0 @@ -CreateCombinator("arithmetic-combinator", { - and_symbol_sprites = Baseless.Sprite4Way, - divide_symbol_sprites = Baseless.Sprite4Way, - left_shift_symbol_sprites = Baseless.Sprite4Way, - minus_symbol_sprites = Baseless.Sprite4Way, - modulo_symbol_sprites = Baseless.Sprite4Way, - multiply_symbol_sprites = Baseless.Sprite4Way, - or_symbol_sprites = Baseless.Sprite4Way, - plus_symbol_sprites = Baseless.Sprite4Way, - power_symbol_sprites = Baseless.Sprite4Way, - right_shift_symbol_sprites = Baseless.Sprite4Way, - xor_symbol_sprites = Baseless.Sprite4Way, -}) diff --git a/prototypes/entity/arrow.lua b/prototypes/entity/arrow.lua deleted file mode 100644 index c5e176c..0000000 --- a/prototypes/entity/arrow.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateEntity("arrow", { - arrow_picture = Baseless.Sprite, -}) diff --git a/prototypes/entity/artillery-flare.lua b/prototypes/entity/artillery-flare.lua deleted file mode 100644 index 3df4be8..0000000 --- a/prototypes/entity/artillery-flare.lua +++ /dev/null @@ -1,5 +0,0 @@ -CreateEntity("artillery-flare", { - life_time = 1, - pictures = Baseless.AnimationVariations, - map_color = Baseless.Color, -}) diff --git a/prototypes/entity/artillery-projectile.lua b/prototypes/entity/artillery-projectile.lua deleted file mode 100644 index 4178adf..0000000 --- a/prototypes/entity/artillery-projectile.lua +++ /dev/null @@ -1,4 +0,0 @@ -CreateEntity("artillery-projectile", { - reveal_map = false, - map_color = Baseless.Color, -}) diff --git a/prototypes/entity/artillery-turret.lua b/prototypes/entity/artillery-turret.lua deleted file mode 100644 index f81d6b4..0000000 --- a/prototypes/entity/artillery-turret.lua +++ /dev/null @@ -1,8 +0,0 @@ -CreateEntityWithHealth("artillery-turret", { - ammo_stack_limit = 1, - automated_ammo_count = 0, - gun = "dummy-gun", - inventory_size = 1, - manual_range_modifier = 1, - turret_rotation_speed = 1, -}) diff --git a/prototypes/entity/artillery-wagon.lua b/prototypes/entity/artillery-wagon.lua deleted file mode 100644 index e051ce0..0000000 --- a/prototypes/entity/artillery-wagon.lua +++ /dev/null @@ -1,7 +0,0 @@ -CreateRollingStock("artillery-wagon", { - ammo_stack_limit = 1, - gun = "dummy-gun", - inventory_size = 1, - manual_range_modifier = 1, - turret_rotation_speed = 1, -}) diff --git a/prototypes/entity/assembling-machine.lua b/prototypes/entity/assembling-machine.lua deleted file mode 100644 index 88eae2d..0000000 --- a/prototypes/entity/assembling-machine.lua +++ /dev/null @@ -1 +0,0 @@ -CreateAssemblingMachine("assembling-machine", {}) diff --git a/prototypes/entity/beacon.lua b/prototypes/entity/beacon.lua deleted file mode 100644 index 563a14e..0000000 --- a/prototypes/entity/beacon.lua +++ /dev/null @@ -1,10 +0,0 @@ -CreateEntityWithHealth("beacon", { - animation = Baseless.Animation, - animation_shadow = Baseless.Animation, - base_picture = Baseless.Sprite, - distribution_effectivity = 1, - energy_source = Baseless.EnergySource.Void, - energy_usage = "1W", - module_specification = {}, - supply_area_distance = 1, -}) diff --git a/prototypes/entity/beam.lua b/prototypes/entity/beam.lua deleted file mode 100644 index 8632744..0000000 --- a/prototypes/entity/beam.lua +++ /dev/null @@ -1,7 +0,0 @@ -CreateEntity("beam", { - body = Baseless.AnimationVariations, - damage_interval = 1, - head = Baseless.Animation, - tail = Baseless.Animation, - width = 1, -}) diff --git a/prototypes/entity/boiler.lua b/prototypes/entity/boiler.lua deleted file mode 100644 index df1118c..0000000 --- a/prototypes/entity/boiler.lua +++ /dev/null @@ -1,17 +0,0 @@ -CreateEntityWithHealth("boiler", { - burning_cooldown = 0, - energy_consumption = "1W", - energy_source = Baseless.EnergySource.Void, - fire = {}, - fire_glow = {}, - fluid_box = Baseless.FluidBox, - output_fluid_box = Baseless.FluidBox, - structure = - { - north = Baseless.Sprite, - south = Baseless.Sprite, - east = Baseless.Sprite, - west = Baseless.Sprite, - }, - target_temperature = 1, -}) diff --git a/prototypes/entity/burner-generator.lua b/prototypes/entity/burner-generator.lua deleted file mode 100644 index 0d83d91..0000000 --- a/prototypes/entity/burner-generator.lua +++ /dev/null @@ -1,8 +0,0 @@ -if CreateEntityWithHealth("burner-generator", { - animation = Baseless.Animation4Way, - burner = Baseless.EnergySource.Burner(), - energy_source = Baseless.EnergySource.Electric, - max_power_output = "1W", -}) then - Baseless.EnergySource.Burner(true) -end diff --git a/prototypes/entity/car.lua b/prototypes/entity/car.lua deleted file mode 100644 index d701ebc..0000000 --- a/prototypes/entity/car.lua +++ /dev/null @@ -1,8 +0,0 @@ -CreateVehicle("car", { - animation = Baseless.RotatedAnimation, - energy_source = Baseless.EnergySource.Void, - consumption = "1W", - effectivity = 1, - inventory_size = 0, - rotation_speed = 1, -}) diff --git a/prototypes/entity/cargo-wagon.lua b/prototypes/entity/cargo-wagon.lua deleted file mode 100644 index 9787fb0..0000000 --- a/prototypes/entity/cargo-wagon.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateRollingStock("cargo-wagon", { - inventory_size = 1, -}) diff --git a/prototypes/entity/character-corpse.lua b/prototypes/entity/character-corpse.lua deleted file mode 100644 index f15a713..0000000 --- a/prototypes/entity/character-corpse.lua +++ /dev/null @@ -1,4 +0,0 @@ -CreateEntity("character-corpse", { - time_to_live = 0, - picture = Baseless.Animation, -}) diff --git a/prototypes/entity/character.lua b/prototypes/entity/character.lua deleted file mode 100644 index ac4cff6..0000000 --- a/prototypes/entity/character.lua +++ /dev/null @@ -1,31 +0,0 @@ -CreateEntityWithHealth("character", { - animations = - { - { - idle = Baseless.RotatedAnimation, - idle_with_gun = Baseless.RotatedAnimation, - running = Baseless.RotatedAnimation, - running_with_gun = Baseless.RotatedAnimation, - mining_with_tool = Baseless.RotatedAnimation, - }, - }, - build_distance = 0, - damage_hit_tint = Baseless.Color, - distance_per_frame = 0, - drop_item_distance = 0, - eat = Baseless.Sound, - heartbeat = Baseless.Sound, - inventory_size = 0, - item_pickup_distance = 0, - loot_pickup_distance = 0, - maximum_corner_sliding_distance = 0, - mining_speed = 0, - mining_with_tool_particles_animation_positions = {}, - reach_distance = 0, - reach_resource_distance = 0, - running_sound_animation_positions = {}, - running_speed = 0, - ticks_to_keep_aiming_direction = 0, - ticks_to_keep_gun = 0, - ticks_to_stay_in_combat = 0, -}) diff --git a/prototypes/entity/cliff.lua b/prototypes/entity/cliff.lua deleted file mode 100644 index b14ec6b..0000000 --- a/prototypes/entity/cliff.lua +++ /dev/null @@ -1,34 +0,0 @@ -Baseless.OrientedCliffPrototype = -{ - collision_bounding_box = Baseless.BoundingBox, - pictures = Baseless.SpriteVariations, - fill_volume = 1, -} - -CreateEntity("cliff", { - grid_offset = {0, 0}, - grid_size = {1, 1}, - orientations = - { - west_to_east = Baseless.OrientedCliffPrototype, - north_to_south = Baseless.OrientedCliffPrototype, - east_to_west = Baseless.OrientedCliffPrototype, - south_to_north = Baseless.OrientedCliffPrototype, - west_to_north = Baseless.OrientedCliffPrototype, - north_to_east = Baseless.OrientedCliffPrototype, - east_to_south = Baseless.OrientedCliffPrototype, - south_to_west = Baseless.OrientedCliffPrototype, - west_to_south = Baseless.OrientedCliffPrototype, - north_to_west = Baseless.OrientedCliffPrototype, - east_to_north = Baseless.OrientedCliffPrototype, - south_to_east = Baseless.OrientedCliffPrototype, - west_to_none = Baseless.OrientedCliffPrototype, - none_to_east = Baseless.OrientedCliffPrototype, - north_to_none = Baseless.OrientedCliffPrototype, - none_to_south = Baseless.OrientedCliffPrototype, - east_to_none = Baseless.OrientedCliffPrototype, - none_to_west = Baseless.OrientedCliffPrototype, - south_to_none = Baseless.OrientedCliffPrototype, - none_to_north = Baseless.OrientedCliffPrototype, - }, -}) diff --git a/prototypes/entity/combat-robot.lua b/prototypes/entity/combat-robot.lua deleted file mode 100644 index 24a6229..0000000 --- a/prototypes/entity/combat-robot.lua +++ /dev/null @@ -1,10 +0,0 @@ -if CreateFlyingRobot("combat-robot", { - attack_parameters = Baseless.AttackParameters.Stream(), - idle = Baseless.RotatedAnimation, - in_motion = Baseless.RotatedAnimation, - shadow_idle = Baseless.RotatedAnimation, - shadow_in_motion = Baseless.RotatedAnimation, - time_to_live = 1, -}) then - Baseless.AttackParameters.Stream(true) -end diff --git a/prototypes/entity/constant-combinator.lua b/prototypes/entity/constant-combinator.lua deleted file mode 100644 index 3e4fd02..0000000 --- a/prototypes/entity/constant-combinator.lua +++ /dev/null @@ -1,7 +0,0 @@ -CreateEntityWithHealth("constant-combinator", { - activity_led_light_offsets = Baseless.CombinatorOffsets, - activity_led_sprites = Baseless.Sprite4Way, - circuit_wire_connection_points = Baseless.WireConnectionPoint.Combinator, - item_slot_count = 0, - sprites = Baseless.Sprite4Way, -}) diff --git a/prototypes/entity/construction-robot.lua b/prototypes/entity/construction-robot.lua deleted file mode 100644 index 360680a..0000000 --- a/prototypes/entity/construction-robot.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateRobotWithLogisticInterface("construction-robot", { - construction_vector = {0, 0}, -}) diff --git a/prototypes/entity/container.lua b/prototypes/entity/container.lua deleted file mode 100644 index cc9ab6b..0000000 --- a/prototypes/entity/container.lua +++ /dev/null @@ -1 +0,0 @@ -CreateContainer("container", {}) diff --git a/prototypes/entity/corpse.lua b/prototypes/entity/corpse.lua deleted file mode 100644 index 1789d77..0000000 --- a/prototypes/entity/corpse.lua +++ /dev/null @@ -1 +0,0 @@ -CreateCorpse("corpse", {}) diff --git a/prototypes/entity/curved-rail.lua b/prototypes/entity/curved-rail.lua deleted file mode 100644 index 7bb99ef..0000000 --- a/prototypes/entity/curved-rail.lua +++ /dev/null @@ -1,3 +0,0 @@ -if Baseless.Needs.RailEntity then - CreateRail("curved-rail", {}) -end diff --git a/prototypes/entity/decider-combinator.lua b/prototypes/entity/decider-combinator.lua deleted file mode 100644 index 9103e73..0000000 --- a/prototypes/entity/decider-combinator.lua +++ /dev/null @@ -1,8 +0,0 @@ -CreateCombinator("decider-combinator", { - equal_symbol_sprites = Baseless.Sprite4Way, - greater_or_equal_symbol_sprites = Baseless.Sprite4Way, - greater_symbol_sprites = Baseless.Sprite4Way, - less_or_equal_symbol_sprites = Baseless.Sprite4Way, - less_symbol_sprites = Baseless.Sprite4Way, - not_equal_symbol_sprites = Baseless.Sprite4Way, -}) diff --git a/prototypes/entity/deconstructible-tile-proxy.lua b/prototypes/entity/deconstructible-tile-proxy.lua deleted file mode 100644 index 019f786..0000000 --- a/prototypes/entity/deconstructible-tile-proxy.lua +++ /dev/null @@ -1 +0,0 @@ -CreateEntity("deconstructible-tile-proxy", {}) diff --git a/prototypes/entity/decorative.lua b/prototypes/entity/decorative.lua deleted file mode 100644 index a1995c3..0000000 --- a/prototypes/entity/decorative.lua +++ /dev/null @@ -1 +0,0 @@ -CreateEntity("decorative", {}) diff --git a/prototypes/entity/electric-energy-interface.lua b/prototypes/entity/electric-energy-interface.lua deleted file mode 100644 index 124db8a..0000000 --- a/prototypes/entity/electric-energy-interface.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateEntityWithHealth("electric-energy-interface", { - energy_source = Baseless.EnergySource.Void, -}) diff --git a/prototypes/entity/electric-pole.lua b/prototypes/entity/electric-pole.lua deleted file mode 100644 index 0223004..0000000 --- a/prototypes/entity/electric-pole.lua +++ /dev/null @@ -1,5 +0,0 @@ -CreateEntityWithHealth("electric-pole", { - connection_points = Baseless.WireConnectionPoint.Pole, - pictures = Baseless.RotatedSprite, - supply_area_distance = 1, -}) diff --git a/prototypes/entity/electric-turret.lua b/prototypes/entity/electric-turret.lua deleted file mode 100644 index 4b8ba22..0000000 --- a/prototypes/entity/electric-turret.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateTurret("electric-turret", { - energy_source = Baseless.EnergySource.Void, -}) diff --git a/prototypes/entity/entity-ghost.lua b/prototypes/entity/entity-ghost.lua deleted file mode 100644 index cebbe1c..0000000 --- a/prototypes/entity/entity-ghost.lua +++ /dev/null @@ -1 +0,0 @@ -CreateEntity("entity-ghost", {}) diff --git a/prototypes/entity/explosion.lua b/prototypes/entity/explosion.lua deleted file mode 100644 index e7c5278..0000000 --- a/prototypes/entity/explosion.lua +++ /dev/null @@ -1 +0,0 @@ -CreateExplosion("explosion", {}) diff --git a/prototypes/entity/fire.lua b/prototypes/entity/fire.lua deleted file mode 100644 index 23b86ab..0000000 --- a/prototypes/entity/fire.lua +++ /dev/null @@ -1,7 +0,0 @@ -if CreateEntity("fire", { - damage_per_tick = Baseless.DamagePrototype(), - spread_delay = 1, - spread_delay_deviation = 1, -}) then - Baseless.DamagePrototype(true) -end diff --git a/prototypes/entity/fish.lua b/prototypes/entity/fish.lua deleted file mode 100644 index 471ea84..0000000 --- a/prototypes/entity/fish.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateEntityWithHealth("fish", { - pictures = Baseless.SpriteVariations, -}) diff --git a/prototypes/entity/flame-thrower-explosion.lua b/prototypes/entity/flame-thrower-explosion.lua deleted file mode 100644 index 991b709..0000000 --- a/prototypes/entity/flame-thrower-explosion.lua +++ /dev/null @@ -1,6 +0,0 @@ -if CreateExplosion("flame-thrower-explosion", { - damage = Baseless.DamagePrototype(), - slow_down_factor = 1, -}) then - Baseless.DamagePrototype(true) -end diff --git a/prototypes/entity/fluid-turret.lua b/prototypes/entity/fluid-turret.lua deleted file mode 100644 index 3fe1010..0000000 --- a/prototypes/entity/fluid-turret.lua +++ /dev/null @@ -1,7 +0,0 @@ -CreateTurret("fluid-turret", { - activation_buffer_ratio = 1, - fluid_box = Baseless.FluidBox, - fluid_buffer_input_flow = 1, - fluid_buffer_size = 1, - turret_base_has_direction = true, -}) diff --git a/prototypes/entity/fluid-wagon.lua b/prototypes/entity/fluid-wagon.lua deleted file mode 100644 index e549cd4..0000000 --- a/prototypes/entity/fluid-wagon.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateRollingStock("fluid-wagon", { - capacity = 1, -}) diff --git a/prototypes/entity/flying-text.lua b/prototypes/entity/flying-text.lua deleted file mode 100644 index 578addc..0000000 --- a/prototypes/entity/flying-text.lua +++ /dev/null @@ -1,4 +0,0 @@ -CreateEntity("flying-text", { - speed = 1, - time_to_live = 1, -}) diff --git a/prototypes/entity/furnace.lua b/prototypes/entity/furnace.lua deleted file mode 100644 index e7f0867..0000000 --- a/prototypes/entity/furnace.lua +++ /dev/null @@ -1,4 +0,0 @@ -CreateCraftingMachine("furnace", { - result_inventory_size = 1, - source_inventory_size = 1, -}) diff --git a/prototypes/entity/gate.lua b/prototypes/entity/gate.lua deleted file mode 100644 index 717bd89..0000000 --- a/prototypes/entity/gate.lua +++ /dev/null @@ -1,16 +0,0 @@ -CreateEntityWithHealth("gate", { - activation_distance = 1, - close_sound = Baseless.Sound, - horizontal_animation = Baseless.Animation, - horizontal_rail_animation_left = Baseless.Animation, - horizontal_rail_animation_right = Baseless.Animation, - horizontal_rail_base = Baseless.Animation, - open_sound = Baseless.Sound, - opening_speed = 1, - timeout_to_close = 1, - vertical_animation = Baseless.Animation, - vertical_rail_animation_left = Baseless.Animation, - vertical_rail_animation_right = Baseless.Animation, - vertical_rail_base = Baseless.Animation, - wall_patch = Baseless.Animation, -}) diff --git a/prototypes/entity/generator.lua b/prototypes/entity/generator.lua deleted file mode 100644 index 9e28ab9..0000000 --- a/prototypes/entity/generator.lua +++ /dev/null @@ -1,10 +0,0 @@ -CreateEntityWithHealth("generator", { - effectivity = 1, - energy_source = Baseless.EnergySource.Void, - fluid_box = Baseless.FluidBox, - fluid_usage_per_tick = 1, - horizontal_animation = Baseless.Animation, - maximum_temperature = 1, - vertical_animation = Baseless.Animation, - max_power_output = "1W", -}) diff --git a/prototypes/entity/heat-interface.lua b/prototypes/entity/heat-interface.lua deleted file mode 100644 index 3d6828e..0000000 --- a/prototypes/entity/heat-interface.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateEntityWithHealth("heat-interface", { - heat_buffer = Baseless.HeatBuffer, -}) diff --git a/prototypes/entity/heat-pipe.lua b/prototypes/entity/heat-pipe.lua deleted file mode 100644 index e3708f3..0000000 --- a/prototypes/entity/heat-pipe.lua +++ /dev/null @@ -1,25 +0,0 @@ -Baseless.ConnectableEntityGraphics = -{ - single = Baseless.SpriteVariations, - straight_vertical = Baseless.SpriteVariations, - straight_horizontal = Baseless.SpriteVariations, - corner_right_down = Baseless.SpriteVariations, - corner_left_down = Baseless.SpriteVariations, - corner_right_up = Baseless.SpriteVariations, - corner_left_up = Baseless.SpriteVariations, - t_up = Baseless.SpriteVariations, - t_right = Baseless.SpriteVariations, - t_down = Baseless.SpriteVariations, - t_left = Baseless.SpriteVariations, - ending_up = Baseless.SpriteVariations, - ending_right = Baseless.SpriteVariations, - ending_down = Baseless.SpriteVariations, - ending_left = Baseless.SpriteVariations, - cross = Baseless.SpriteVariations, -} - -CreateEntityWithHealth("heat-pipe", { - connection_sprites = Baseless.ConnectableEntityGraphics, - heat_buffer = Baseless.HeatBuffer, - heat_glow_sprites = Baseless.ConnectableEntityGraphics, -}) diff --git a/prototypes/entity/highlight-box.lua b/prototypes/entity/highlight-box.lua deleted file mode 100644 index 369b66c..0000000 --- a/prototypes/entity/highlight-box.lua +++ /dev/null @@ -1 +0,0 @@ -CreateEntity("highlight-box", {}) diff --git a/prototypes/entity/infinity-container.lua b/prototypes/entity/infinity-container.lua deleted file mode 100644 index 591c1c1..0000000 --- a/prototypes/entity/infinity-container.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateLogisticContainer("infinity-container", { - erase_contents_when_mined = true, -}) diff --git a/prototypes/entity/infinity-pipe.lua b/prototypes/entity/infinity-pipe.lua deleted file mode 100644 index 951f4fe..0000000 --- a/prototypes/entity/infinity-pipe.lua +++ /dev/null @@ -1 +0,0 @@ -CreatePipe("infinity-pipe", {}) diff --git a/prototypes/entity/inserter.lua b/prototypes/entity/inserter.lua deleted file mode 100644 index 040b039..0000000 --- a/prototypes/entity/inserter.lua +++ /dev/null @@ -1,15 +0,0 @@ -CreateEntityWithHealth("inserter", { - energy_source = Baseless.EnergySource.Void, - extension_speed = 1, - hand_base_picture = Baseless.Sprite, - hand_base_shadow = Baseless.Sprite, - hand_closed_picture = Baseless.Sprite, - hand_closed_shadow = Baseless.Sprite, - hand_open_picture = Baseless.Sprite, - hand_open_shadow = Baseless.Sprite, - insert_position = {0, 1}, - pickup_position = {0, -1}, - platform_picture = Baseless.Sprite4Way, - rotation_speed = 1, - collision_box = {{-0.1, -0.1}, {0.1, 0.1}}, -}) diff --git a/prototypes/entity/item-entity.lua b/prototypes/entity/item-entity.lua deleted file mode 100644 index 397faa8..0000000 --- a/prototypes/entity/item-entity.lua +++ /dev/null @@ -1 +0,0 @@ -CreateEntity("item-entity", {}) diff --git a/prototypes/entity/item-request-proxy.lua b/prototypes/entity/item-request-proxy.lua deleted file mode 100644 index 912059e..0000000 --- a/prototypes/entity/item-request-proxy.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateEntity("item-request-proxy", { - picture = Baseless.Sprite, -}) diff --git a/prototypes/entity/lab.lua b/prototypes/entity/lab.lua deleted file mode 100644 index 0c65fa8..0000000 --- a/prototypes/entity/lab.lua +++ /dev/null @@ -1,9 +0,0 @@ -if CreateEntityWithHealth("lab", { - energy_source = Baseless.EnergySource.Void, - energy_usage = "1W", - inputs = {Baseless.ScienceType()}, - off_animation = Baseless.Animation, - on_animation = Baseless.Animation, -}) then - Baseless.ScienceType(true) -end diff --git a/prototypes/entity/lamp.lua b/prototypes/entity/lamp.lua deleted file mode 100644 index e585b8c..0000000 --- a/prototypes/entity/lamp.lua +++ /dev/null @@ -1,6 +0,0 @@ -CreateEntityWithHealth("lamp", { - energy_source = Baseless.EnergySource.Void, - energy_usage_per_tick = "1W", - picture_off = Baseless.Sprite, - picture_on = Baseless.Sprite, -}) diff --git a/prototypes/entity/land-mine.lua b/prototypes/entity/land-mine.lua deleted file mode 100644 index 636f4e4..0000000 --- a/prototypes/entity/land-mine.lua +++ /dev/null @@ -1,5 +0,0 @@ -CreateEntityWithHealth("land-mine", { - picture_safe = Baseless.Sprite, - picture_set = Baseless.Sprite, - trigger_radius = 1, -}) diff --git a/prototypes/entity/leaf-particle.lua b/prototypes/entity/leaf-particle.lua deleted file mode 100644 index 322e4e1..0000000 --- a/prototypes/entity/leaf-particle.lua +++ /dev/null @@ -1,7 +0,0 @@ -data:extend -{ - { - type = "leaf-particle", - name = "leaf-particle-for-migration", - }, -} diff --git a/prototypes/entity/loader-1x1.lua b/prototypes/entity/loader-1x1.lua deleted file mode 100644 index de4e913..0000000 --- a/prototypes/entity/loader-1x1.lua +++ /dev/null @@ -1,8 +0,0 @@ -CreateTransportBeltConnectable("loader-1x1", { - filter_count = 0, - structure = - { - direction_in = Baseless.Sprite4Way, - direction_out = Baseless.Sprite4Way, - }, -}) diff --git a/prototypes/entity/loader.lua b/prototypes/entity/loader.lua deleted file mode 100644 index a67b5b2..0000000 --- a/prototypes/entity/loader.lua +++ /dev/null @@ -1,8 +0,0 @@ -CreateTransportBeltConnectable("loader", { - filter_count = 0, - structure = - { - direction_in = Baseless.Sprite4Way, - direction_out = Baseless.Sprite4Way, - }, -}) diff --git a/prototypes/entity/locomotive.lua b/prototypes/entity/locomotive.lua deleted file mode 100644 index 78e6064..0000000 --- a/prototypes/entity/locomotive.lua +++ /dev/null @@ -1,5 +0,0 @@ -CreateRollingStock("locomotive", { - energy_source = Baseless.EnergySource.Void, - max_power = "1W", - reversing_power_modifier = 1, -}) diff --git a/prototypes/entity/logistic-container.lua b/prototypes/entity/logistic-container.lua deleted file mode 100644 index f7ab171..0000000 --- a/prototypes/entity/logistic-container.lua +++ /dev/null @@ -1 +0,0 @@ -CreateLogisticContainer("logistic-container", {}) diff --git a/prototypes/entity/logistic-robot.lua b/prototypes/entity/logistic-robot.lua deleted file mode 100644 index 1319120..0000000 --- a/prototypes/entity/logistic-robot.lua +++ /dev/null @@ -1 +0,0 @@ -CreateRobotWithLogisticInterface("logistic-robot", {}) diff --git a/prototypes/entity/market.lua b/prototypes/entity/market.lua deleted file mode 100644 index bcfed60..0000000 --- a/prototypes/entity/market.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateEntityWithHealth("market", { - picture = Baseless.Sprite, -}) diff --git a/prototypes/entity/mining-drill.lua b/prototypes/entity/mining-drill.lua deleted file mode 100644 index 530c19d..0000000 --- a/prototypes/entity/mining-drill.lua +++ /dev/null @@ -1,11 +0,0 @@ -if CreateEntityWithHealth("mining-drill", { - animations = Baseless.Animation4Way, - energy_source = Baseless.EnergySource.Void, - energy_usage = "1W", - mining_speed = 1, - resource_categories = {Baseless.ResourceType()}, - resource_searching_radius = 1, - vector_to_place_result = {0, 0}, -}) then - Baseless.ResourceType(true) -end diff --git a/prototypes/entity/offshore-pump.lua b/prototypes/entity/offshore-pump.lua deleted file mode 100644 index 8a44555..0000000 --- a/prototypes/entity/offshore-pump.lua +++ /dev/null @@ -1,11 +0,0 @@ -if CreateEntityWithHealth("offshore-pump", { - fluid = "dummy-fluid", - fluid_box = Baseless.FluidBox, - pumping_speed = 1, - graphics_set = - { - animation = Baseless.Animation4Way, - }, -}) then - Baseless.Needs.Fluid = true -end diff --git a/prototypes/entity/particle-source.lua b/prototypes/entity/particle-source.lua deleted file mode 100644 index e3c746d..0000000 --- a/prototypes/entity/particle-source.lua +++ /dev/null @@ -1,10 +0,0 @@ -if CreateEntity("particle-source", { - height = 1, - horizontal_speed = 1, - particle = "dummy-optimized-particle", - time_before_start = 1, - time_to_live = 1, - vertical_speed = 1, -}) then - Baseless.Needs.Particle = true -end diff --git a/prototypes/entity/particle.lua b/prototypes/entity/particle.lua deleted file mode 100644 index 2701552..0000000 --- a/prototypes/entity/particle.lua +++ /dev/null @@ -1,7 +0,0 @@ -data:extend -{ - { - type = "particle", - name = "particle-for-migration", - }, -} diff --git a/prototypes/entity/pipe-to-ground.lua b/prototypes/entity/pipe-to-ground.lua deleted file mode 100644 index 006f533..0000000 --- a/prototypes/entity/pipe-to-ground.lua +++ /dev/null @@ -1,10 +0,0 @@ -CreateEntityWithHealth("pipe-to-ground", { - fluid_box = Baseless.FluidBox, - pictures = - { - down = Baseless.Sprite, - up = Baseless.Sprite, - left = Baseless.Sprite, - right = Baseless.Sprite, - }, -}) diff --git a/prototypes/entity/pipe.lua b/prototypes/entity/pipe.lua deleted file mode 100644 index 5815e1a..0000000 --- a/prototypes/entity/pipe.lua +++ /dev/null @@ -1 +0,0 @@ -CreatePipe("pipe", {}) diff --git a/prototypes/entity/player-port.lua b/prototypes/entity/player-port.lua deleted file mode 100644 index 1eced48..0000000 --- a/prototypes/entity/player-port.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateEntityWithHealth("player-port", { - animation = Baseless.Animation, -}) diff --git a/prototypes/entity/power-switch.lua b/prototypes/entity/power-switch.lua deleted file mode 100644 index ed69174..0000000 --- a/prototypes/entity/power-switch.lua +++ /dev/null @@ -1,11 +0,0 @@ -CreateEntityWithHealth("power-switch", { - circuit_wire_connection_point = Baseless.WireConnectionPoint.PowerSwitch, - led_off = Baseless.Sprite, - led_on = Baseless.Sprite, - left_wire_connection_point = Baseless.WireConnectionPoint.PowerSwitch, - overlay_loop = Baseless.Animation, - overlay_start = Baseless.Animation, - overlay_start_delay = 0, - power_on_animation = Baseless.Animation, - right_wire_connection_point = Baseless.WireConnectionPoint.PowerSwitch, -}) diff --git a/prototypes/entity/programmable-speaker.lua b/prototypes/entity/programmable-speaker.lua deleted file mode 100644 index 741d457..0000000 --- a/prototypes/entity/programmable-speaker.lua +++ /dev/null @@ -1,7 +0,0 @@ -CreateEntityWithHealth("programmable-speaker", { - energy_source = Baseless.EnergySource.Void, - energy_usage_per_tick = "1W", - instruments = {}, - maximum_polyphony = 1, - sprite = Baseless.Sprite, -}) diff --git a/prototypes/entity/projectile.lua b/prototypes/entity/projectile.lua deleted file mode 100644 index 3367d79..0000000 --- a/prototypes/entity/projectile.lua +++ /dev/null @@ -1,4 +0,0 @@ -CreateEntity("projectile", { - acceleration = 1, - animation = Baseless.Animation, -}) diff --git a/prototypes/entity/pump.lua b/prototypes/entity/pump.lua deleted file mode 100644 index c52fa41..0000000 --- a/prototypes/entity/pump.lua +++ /dev/null @@ -1,7 +0,0 @@ -CreateEntityWithHealth("pump", { - animations = Baseless.Animation4Way, - energy_source = Baseless.EnergySource.Void, - energy_usage = "1W", - fluid_box = Baseless.FluidBox, - pumping_speed = 1, -}) diff --git a/prototypes/entity/radar.lua b/prototypes/entity/radar.lua deleted file mode 100644 index e89a501..0000000 --- a/prototypes/entity/radar.lua +++ /dev/null @@ -1,9 +0,0 @@ -CreateEntityWithHealth("radar", { - energy_per_nearby_scan = "1W", - energy_per_sector = "1W", - energy_source = Baseless.EnergySource.Void, - energy_usage = "1W", - max_distance_of_nearby_sector_revealed = 1, - max_distance_of_sector_revealed = 1, - pictures = Baseless.RotatedSprite, -}) diff --git a/prototypes/entity/rail-chain-signal.lua b/prototypes/entity/rail-chain-signal.lua deleted file mode 100644 index 74e96df..0000000 --- a/prototypes/entity/rail-chain-signal.lua +++ /dev/null @@ -1,13 +0,0 @@ -CreateRailSignalBase("rail-chain-signal", { - selection_box_offsets = - { - {0, 0}, - {0, 0}, - {0, 0}, - {0, 0}, - {0, 0}, - {0, 0}, - {0, 0}, - {0, 0}, - }, -}) diff --git a/prototypes/entity/rail-remnants.lua b/prototypes/entity/rail-remnants.lua deleted file mode 100644 index b82e2a6..0000000 --- a/prototypes/entity/rail-remnants.lua +++ /dev/null @@ -1,6 +0,0 @@ -CreateCorpse("rail-remnants", { - bending_type = "turn", - pictures = Baseless.RailPictures, - collision_box = {{-1, -1}, {1, 1}}, - secondary_collision_box = {{-1, -1}, {1, 1}}, -}) diff --git a/prototypes/entity/rail-signal.lua b/prototypes/entity/rail-signal.lua deleted file mode 100644 index 92b37fd..0000000 --- a/prototypes/entity/rail-signal.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateEntityWithHealth("rail-signal", { - animation = Baseless.RotatedAnimation, -}) diff --git a/prototypes/entity/reactor.lua b/prototypes/entity/reactor.lua deleted file mode 100644 index 45791d6..0000000 --- a/prototypes/entity/reactor.lua +++ /dev/null @@ -1,6 +0,0 @@ -CreateEntityWithHealth("reactor", { - consumption = "1W", - energy_source = Baseless.EnergySource.Void, - heat_buffer = Baseless.HeatBuffer, - working_light_picture = Baseless.Sprite, -}) diff --git a/prototypes/entity/resource.lua b/prototypes/entity/resource.lua deleted file mode 100644 index 29ca12d..0000000 --- a/prototypes/entity/resource.lua +++ /dev/null @@ -1,8 +0,0 @@ -CreateEntity("resource", { - stage_counts = {1}, - stages = Baseless.AnimationVariations, - minable = - { - mining_time = 1, - }, -}) diff --git a/prototypes/entity/roboport.lua b/prototypes/entity/roboport.lua deleted file mode 100644 index 5ae7a18..0000000 --- a/prototypes/entity/roboport.lua +++ /dev/null @@ -1,19 +0,0 @@ -CreateEntityWithHealth("roboport", { - base = Baseless.Sprite, - base_animation = Baseless.Animation, - base_patch = Baseless.Sprite, - charge_approach_distance = 1, - charging_energy = "1W", - construction_radius = 1, - door_animation_down = Baseless.Animation, - door_animation_up = Baseless.Animation, - energy_source = Baseless.EnergySource.Void, - energy_usage = "1W", - logistics_radius = 1, - material_slots_count = 0, - recharge_minimum = "1W", - recharging_animation = Baseless.Animation, - request_to_open_door_timeout = 1, - robot_slots_count = 0, - spawn_and_station_height = 1, -}) diff --git a/prototypes/entity/rocket-silo-rocket-shadow.lua b/prototypes/entity/rocket-silo-rocket-shadow.lua deleted file mode 100644 index 07075cf..0000000 --- a/prototypes/entity/rocket-silo-rocket-shadow.lua +++ /dev/null @@ -1 +0,0 @@ -CreateEntity("rocket-silo-rocket-shadow", {}) diff --git a/prototypes/entity/rocket-silo-rocket.lua b/prototypes/entity/rocket-silo-rocket.lua deleted file mode 100644 index 3919dbb..0000000 --- a/prototypes/entity/rocket-silo-rocket.lua +++ /dev/null @@ -1,31 +0,0 @@ -if Baseless.Needs.RocketEntity then - CreateEntity("rocket-silo-rocket", { - effects_fade_in_end_distance = 1, - effects_fade_in_start_distance = 1, - engine_starting_speed = 1, - flying_acceleration = 1, - flying_speed = 1, - full_render_layer_switch_distance = 1, - inventory_size = 1, - rising_speed = 1, - rocket_flame_animation = Baseless.Animation, - rocket_flame_left_animation = Baseless.Animation, - rocket_flame_left_rotation = 1, - rocket_flame_right_animation = Baseless.Animation, - rocket_flame_right_rotation = 1, - rocket_glare_overlay_sprite = Baseless.Sprite, - rocket_launch_offset = {0, 0}, - rocket_render_layer_switch_distance = 1, - rocket_rise_offset = {0, 0}, - rocket_shadow_sprite = Baseless.Sprite, - rocket_smoke_bottom1_animation = Baseless.Animation, - rocket_smoke_bottom2_animation = Baseless.Animation, - rocket_smoke_top1_animation = Baseless.Animation, - rocket_smoke_top2_animation = Baseless.Animation, - rocket_smoke_top3_animation = Baseless.Animation, - rocket_sprite = Baseless.Sprite, - rocket_visible_distance_from_center = 1, - shadow_fade_out_end_ratio = 1, - shadow_fade_out_start_ratio = 1 - }) -end diff --git a/prototypes/entity/rocket-silo.lua b/prototypes/entity/rocket-silo.lua deleted file mode 100644 index 91f85f0..0000000 --- a/prototypes/entity/rocket-silo.lua +++ /dev/null @@ -1,34 +0,0 @@ -if CreateAssemblingMachine("rocket-silo", { - active_energy_usage = "1W", - arm_01_back_animation = Baseless.Animation, - arm_02_right_animation = Baseless.Animation, - arm_03_front_animation = Baseless.Animation, - base_day_sprite = Baseless.Sprite, - base_front_sprite = Baseless.Sprite, - door_back_open_offset = {0, 0}, - door_back_sprite = Baseless.Sprite, - door_front_open_offset = {0, 0}, - door_front_sprite = Baseless.Sprite, - door_opening_speed = 1, - energy_usage = "1W", - hole_clipping_box = Baseless.BoundingBox, - hole_light_sprite = Baseless.Sprite, - hole_sprite = Baseless.Sprite, - idle_energy_usage = "1W", - lamp_energy_usage = "1W", - light_blinking_speed = 1, - red_lights_back_sprites = Baseless.Sprite, - red_lights_front_sprites = Baseless.Sprite, - rocket_entity = "dummy-rocket-silo-rocket", - rocket_glow_overlay_sprite = Baseless.Sprite, - rocket_parts_required = 1, - rocket_shadow_overlay_sprite = Baseless.Sprite, - satellite_animation = Baseless.Animation, - satellite_shadow_animation = Baseless.Animation, - shadow_sprite = Baseless.Sprite, - silo_fade_out_end_distance = 1, - silo_fade_out_start_distance = 1, - times_to_blink = 1, -}) then - Baseless.Needs.RocketEntity = true -end diff --git a/prototypes/entity/simple-entity-with-force.lua b/prototypes/entity/simple-entity-with-force.lua deleted file mode 100644 index 49e43ce..0000000 --- a/prototypes/entity/simple-entity-with-force.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateEntityWithHealth("simple-entity-with-force", { - picture = Baseless.Sprite, -}) diff --git a/prototypes/entity/simple-entity-with-owner.lua b/prototypes/entity/simple-entity-with-owner.lua deleted file mode 100644 index bfbebc0..0000000 --- a/prototypes/entity/simple-entity-with-owner.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateEntityWithHealth("simple-entity-with-owner", { - picture = Baseless.Sprite, -}) diff --git a/prototypes/entity/simple-entity.lua b/prototypes/entity/simple-entity.lua deleted file mode 100644 index a0ae060..0000000 --- a/prototypes/entity/simple-entity.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateEntityWithHealth("simple-entity", { - picture = Baseless.Sprite, -}) diff --git a/prototypes/entity/smoke-with-trigger.lua b/prototypes/entity/smoke-with-trigger.lua deleted file mode 100644 index bbd794b..0000000 --- a/prototypes/entity/smoke-with-trigger.lua +++ /dev/null @@ -1 +0,0 @@ -CreateSmoke("smoke-with-trigger", {}) diff --git a/prototypes/entity/smoke.lua b/prototypes/entity/smoke.lua deleted file mode 100644 index 656c5ea..0000000 --- a/prototypes/entity/smoke.lua +++ /dev/null @@ -1,8 +0,0 @@ -data:extend -{ - { - type = "smoke", - name = "smoke-for-migration", - animation = Baseless.Animation, - }, -} diff --git a/prototypes/entity/solar-panel.lua b/prototypes/entity/solar-panel.lua deleted file mode 100644 index 1633a31..0000000 --- a/prototypes/entity/solar-panel.lua +++ /dev/null @@ -1,5 +0,0 @@ -CreateEntityWithHealth("solar-panel", { - energy_source = Baseless.EnergySource.Void, - picture = Baseless.SpriteVariations, - production = "1W", -}) diff --git a/prototypes/entity/speech-bubble.lua b/prototypes/entity/speech-bubble.lua deleted file mode 100644 index 7672e96..0000000 --- a/prototypes/entity/speech-bubble.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateEntity("speech-bubble", { - style = "compilatron_speech_bubble", -}) diff --git a/prototypes/entity/splitter.lua b/prototypes/entity/splitter.lua deleted file mode 100644 index 1b64b20..0000000 --- a/prototypes/entity/splitter.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateTransportBeltConnectable("splitter", { - structure = Baseless.Animation4Way, -}) diff --git a/prototypes/entity/sticker.lua b/prototypes/entity/sticker.lua deleted file mode 100644 index f077942..0000000 --- a/prototypes/entity/sticker.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateEntity("sticker", { - duration_in_ticks = 1, -}) diff --git a/prototypes/entity/storage-tank.lua b/prototypes/entity/storage-tank.lua deleted file mode 100644 index a7a95bd..0000000 --- a/prototypes/entity/storage-tank.lua +++ /dev/null @@ -1,13 +0,0 @@ -CreateEntityWithHealth("storage-tank", { - flow_length_in_ticks = 1, - fluid_box = Baseless.FluidBox, - pictures = - { - picture = Baseless.Sprite4Way, - window_background = Baseless.Sprite, - fluid_background = Baseless.Sprite, - flow_sprite = Baseless.Sprite, - gas_flow = Baseless.Animation, - }, - window_bounding_box = Baseless.BoundingBox, -}) diff --git a/prototypes/entity/straight-rail.lua b/prototypes/entity/straight-rail.lua deleted file mode 100644 index 1c63f60..0000000 --- a/prototypes/entity/straight-rail.lua +++ /dev/null @@ -1,3 +0,0 @@ -if Baseless.Needs.RailEntity then - CreateRail("straight-rail", {}) -end diff --git a/prototypes/entity/stream.lua b/prototypes/entity/stream.lua deleted file mode 100644 index f800bf5..0000000 --- a/prototypes/entity/stream.lua +++ /dev/null @@ -1,6 +0,0 @@ -CreateEntity("stream", { - particle_horizontal_speed = 1, - particle_horizontal_speed_deviation = 0, - particle_spawn_interval = 1, - particle_vertical_acceleration = 1, -}) diff --git a/prototypes/entity/tile-ghost.lua b/prototypes/entity/tile-ghost.lua deleted file mode 100644 index 1416e26..0000000 --- a/prototypes/entity/tile-ghost.lua +++ /dev/null @@ -1 +0,0 @@ -CreateEntity("tile-ghost", {}) diff --git a/prototypes/entity/train-stop.lua b/prototypes/entity/train-stop.lua deleted file mode 100644 index 69c5894..0000000 --- a/prototypes/entity/train-stop.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateEntityWithHealth("train-stop", { - animation_ticks_per_frame = 1, -}) diff --git a/prototypes/entity/transport-belt.lua b/prototypes/entity/transport-belt.lua deleted file mode 100644 index 2d3af35..0000000 --- a/prototypes/entity/transport-belt.lua +++ /dev/null @@ -1,4 +0,0 @@ -CreateTransportBeltConnectable("transport-belt", { - connector_frame_sprites = Baseless.TransportBeltConnectorFrame, - animations = Baseless.BeltAnimation, -}) diff --git a/prototypes/entity/tree.lua b/prototypes/entity/tree.lua deleted file mode 100644 index 78f16e1..0000000 --- a/prototypes/entity/tree.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateEntityWithHealth("tree", { - pictures = Baseless.SpriteVariations, -}) diff --git a/prototypes/entity/turret.lua b/prototypes/entity/turret.lua deleted file mode 100644 index 0831f70..0000000 --- a/prototypes/entity/turret.lua +++ /dev/null @@ -1 +0,0 @@ -CreateTurret("turret", {}) diff --git a/prototypes/entity/underground-belt.lua b/prototypes/entity/underground-belt.lua deleted file mode 100644 index ea3e242..0000000 --- a/prototypes/entity/underground-belt.lua +++ /dev/null @@ -1,9 +0,0 @@ -CreateTransportBeltConnectable("underground-belt", { - max_distance = 1, - structure = - { - direction_in = Baseless.Sprite4Way, - direction_out = Baseless.Sprite4Way, - }, - underground_sprite = Baseless.Sprite, -}) diff --git a/prototypes/entity/unit-spawner.lua b/prototypes/entity/unit-spawner.lua deleted file mode 100644 index d6501f7..0000000 --- a/prototypes/entity/unit-spawner.lua +++ /dev/null @@ -1,28 +0,0 @@ -if CreateEntityWithHealth("unit-spawner", { - animations = Baseless.AnimationVariations, - call_for_help_radius = 1, - max_count_of_owned_units = 1, - max_friends_around_to_spawn = 1, - max_richness_for_spawn_shift = 1, - max_spawn_shift = 1, - pollution_absorption_absolute = 1, - pollution_absorption_proportional = 1, - result_units = - { - { - unit = "dummy-unit", - spawn_points = - { - { - evolution_factor = 0, - spawn_weight = 0, - }, - }, - }, - }, - spawning_cooldown = {1, 1}, - spawning_radius = 1, - spawning_spacing = 1, -}) then - Baseless.Needs.UnitEntity = true -end diff --git a/prototypes/entity/unit.lua b/prototypes/entity/unit.lua deleted file mode 100644 index 21cbb76..0000000 --- a/prototypes/entity/unit.lua +++ /dev/null @@ -1,13 +0,0 @@ -if Baseless.Needs.UnitEntity then - if CreateEntityWithHealth("unit", { - attack_parameters = Baseless.AttackParameters.Stream(), - distance_per_frame = 1, - distraction_cooldown = 1, - movement_speed = 1, - pollution_to_join_attack = 1, - run_animation = Baseless.RotatedAnimation, - vision_distance = 1, - }) then - Baseless.AttackParameters.Stream(true) - end -end diff --git a/prototypes/entity/wall.lua b/prototypes/entity/wall.lua deleted file mode 100644 index 48ec665..0000000 --- a/prototypes/entity/wall.lua +++ /dev/null @@ -1,13 +0,0 @@ -CreateEntityWithHealth("wall", { - pictures = - { - single = Baseless.SpriteVariations, - straight_vertical = Baseless.SpriteVariations, - straight_horizontal = Baseless.SpriteVariations, - corner_right_down = Baseless.SpriteVariations, - corner_left_down = Baseless.SpriteVariations, - t_up = Baseless.SpriteVariations, - ending_right = Baseless.SpriteVariations, - ending_left = Baseless.SpriteVariations, - }, -}) diff --git a/prototypes/equipment.lua b/prototypes/equipment.lua new file mode 100644 index 0000000..9aa8aea --- /dev/null +++ b/prototypes/equipment.lua @@ -0,0 +1,21 @@ +local function RegisterEquipmentIfUnique (list) + for _, equipment in pairs(list) do + if Baseless.RegisterIfUnique(equipment) then + Baseless.RegisterIfNew { + Baseless.Make.Item(nil, equipment.name, {}) + } + end + end +end + +RegisterEquipmentIfUnique { + Baseless.Make.ActiveDefenseEquipment(), + Baseless.Make.BatteryEquipment(), + Baseless.Make.BeltImmunityEquipment(), + Baseless.Make.EnergyShieldEquipment(), + Baseless.Make.GeneratorEquipment(), + Baseless.Make.MovementBonusEquipment(), + Baseless.Make.NightVisionEquipment(), + Baseless.Make.RoboportEquipment(), + Baseless.Make.SolarPanelEquipment(), +} diff --git a/prototypes/equipment/active-defense-equipment.lua b/prototypes/equipment/active-defense-equipment.lua deleted file mode 100644 index 9fded0d..0000000 --- a/prototypes/equipment/active-defense-equipment.lua +++ /dev/null @@ -1,6 +0,0 @@ -if CreateEquipment("active-defense-equipment", { - attack_parameters = Baseless.AttackParameters.Stream(), - automatic = true, -}) then - Baseless.AttackParameters.Stream(true) -end diff --git a/prototypes/equipment/battery-equipment.lua b/prototypes/equipment/battery-equipment.lua deleted file mode 100644 index 293bc27..0000000 --- a/prototypes/equipment/battery-equipment.lua +++ /dev/null @@ -1 +0,0 @@ -CreateEquipment("battery-equipment", {}) diff --git a/prototypes/equipment/belt-immunity-equipment.lua b/prototypes/equipment/belt-immunity-equipment.lua deleted file mode 100644 index e0334cd..0000000 --- a/prototypes/equipment/belt-immunity-equipment.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateEquipment("belt-immunity-equipment", { - energy_consumption = "1W", -}) diff --git a/prototypes/equipment/energy-shield-equipment.lua b/prototypes/equipment/energy-shield-equipment.lua deleted file mode 100644 index 8b7015c..0000000 --- a/prototypes/equipment/energy-shield-equipment.lua +++ /dev/null @@ -1,4 +0,0 @@ -CreateEquipment("energy-shield-equipment", { - energy_per_shield = "1W", - max_shield_value = 1, -}) diff --git a/prototypes/equipment/generator-equipment.lua b/prototypes/equipment/generator-equipment.lua deleted file mode 100644 index cea4621..0000000 --- a/prototypes/equipment/generator-equipment.lua +++ /dev/null @@ -1,4 +0,0 @@ -CreateEquipment("generator-equipment", { - power = "1W", - burner = Baseless.EnergySource.Burner(), -}) diff --git a/prototypes/equipment/movement-bonus-equipment.lua b/prototypes/equipment/movement-bonus-equipment.lua deleted file mode 100644 index 6e2eb42..0000000 --- a/prototypes/equipment/movement-bonus-equipment.lua +++ /dev/null @@ -1,4 +0,0 @@ -CreateEquipment("movement-bonus-equipment", { - energy_consumption = "1W", - movement_bonus = 1, -}) diff --git a/prototypes/equipment/night-vision-equipment.lua b/prototypes/equipment/night-vision-equipment.lua deleted file mode 100644 index 4d566f7..0000000 --- a/prototypes/equipment/night-vision-equipment.lua +++ /dev/null @@ -1,5 +0,0 @@ -CreateEquipment("night-vision-equipment", { - color_lookup = {{1, "identity"}}, - energy_input = "1W", - darkness_to_turn_on = 1, -}) diff --git a/prototypes/equipment/roboport-equipment.lua b/prototypes/equipment/roboport-equipment.lua deleted file mode 100644 index 47499c0..0000000 --- a/prototypes/equipment/roboport-equipment.lua +++ /dev/null @@ -1,7 +0,0 @@ -CreateEquipment("roboport-equipment", { - charge_approach_distance = 1, - charging_energy = "1W", - construction_radius = 1, - recharging_animation = Baseless.Animation, - spawn_and_station_height = 1, -}) diff --git a/prototypes/equipment/solar-panel-equipment.lua b/prototypes/equipment/solar-panel-equipment.lua deleted file mode 100644 index 32b70c7..0000000 --- a/prototypes/equipment/solar-panel-equipment.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateEquipment("solar-panel-equipment", { - power = "1W", -}) diff --git a/prototypes/item-group.lua b/prototypes/item-group.lua deleted file mode 100644 index fec512c..0000000 --- a/prototypes/item-group.lua +++ /dev/null @@ -1,16 +0,0 @@ -if Baseless.Needs.ItemGroup then - CreatePrototype("item-group", Baseless.IconSpecification) - CreatePrototype("item-subgroup", {group = "dummy-item-group"}) -end - -if data.raw["item-subgroup"] == nil or - data.raw["item-subgroup"]["other"] == nil then - data:extend - { - { - type = "item-subgroup", - name = "other", - group = "dummy-item-group", - }, - } -end diff --git a/prototypes/item.lua b/prototypes/item.lua new file mode 100644 index 0000000..2f4cd64 --- /dev/null +++ b/prototypes/item.lua @@ -0,0 +1,19 @@ +Baseless.RegisterIfUnique { + Baseless.Make.Ammo(), + Baseless.Make.Armor(), + Baseless.Make.Blueprint(), + Baseless.Make.BlueprintBook(), + Baseless.Make.Capsule(), + Baseless.Make.CopyPasteTool(), + Baseless.Make.DeconstructionItem(), + Baseless.Make.ItemWithEntityData(), + Baseless.Make.ItemWithInventory(), + Baseless.Make.ItemWithLabel(), + Baseless.Make.ItemWithTags(), + Baseless.Make.Module(), + Baseless.Make.RailPlanner(), + Baseless.Make.RepairTool(), + Baseless.Make.SelectionTool(), + Baseless.Make.Tool(), + Baseless.Make.UpgradeItem(), +} diff --git a/prototypes/item/ammo.lua b/prototypes/item/ammo.lua deleted file mode 100644 index 31a5a99..0000000 --- a/prototypes/item/ammo.lua +++ /dev/null @@ -1,5 +0,0 @@ -if CreateItem("ammo", { - ammo_type = Baseless.AmmoType(), -}) then - Baseless.AmmoType(true) -end diff --git a/prototypes/item/armor.lua b/prototypes/item/armor.lua deleted file mode 100644 index 63313b3..0000000 --- a/prototypes/item/armor.lua +++ /dev/null @@ -1 +0,0 @@ -CreateTool("armor", {}) diff --git a/prototypes/item/blueprint-book.lua b/prototypes/item/blueprint-book.lua deleted file mode 100644 index 8e47e9e..0000000 --- a/prototypes/item/blueprint-book.lua +++ /dev/null @@ -1 +0,0 @@ -CreateItemWithInventory("blueprint-book", {}) diff --git a/prototypes/item/blueprint.lua b/prototypes/item/blueprint.lua deleted file mode 100644 index d14503a..0000000 --- a/prototypes/item/blueprint.lua +++ /dev/null @@ -1 +0,0 @@ -CreateSelectionTool("blueprint", {}) diff --git a/prototypes/item/capsule.lua b/prototypes/item/capsule.lua deleted file mode 100644 index dc01319..0000000 --- a/prototypes/item/capsule.lua +++ /dev/null @@ -1,9 +0,0 @@ -if CreateItem("capsule", { - capsule_action = - { - type = "throw", - attack_parameters = Baseless.AttackParameters.Stream(), - }, -}) then - Baseless.AttackParameters.Stream(true) -end diff --git a/prototypes/item/copper-cable.lua b/prototypes/item/copper-cable.lua deleted file mode 100644 index d9f7a47..0000000 --- a/prototypes/item/copper-cable.lua +++ /dev/null @@ -1,14 +0,0 @@ -if data.raw["item"] == nil or - data.raw["item"]["copper-cable"] == nil then - data:extend - { - { - type = "item", - name = "copper-cable", - icon = Baseless.Image, - icon_size = 1, - stack_size = 1, - subgroup = "dummy-item-subgroup", - }, - } -end diff --git a/prototypes/item/copy-paste-tool.lua b/prototypes/item/copy-paste-tool.lua deleted file mode 100644 index 916484a..0000000 --- a/prototypes/item/copy-paste-tool.lua +++ /dev/null @@ -1 +0,0 @@ -CreateSelectionTool("copy-paste-tool", {}) diff --git a/prototypes/item/deconstruction-item.lua b/prototypes/item/deconstruction-item.lua deleted file mode 100644 index 168d8c9..0000000 --- a/prototypes/item/deconstruction-item.lua +++ /dev/null @@ -1 +0,0 @@ -CreateSelectionTool("deconstruction-item", {}) diff --git a/prototypes/item/green-wire.lua b/prototypes/item/green-wire.lua deleted file mode 100644 index ee90779..0000000 --- a/prototypes/item/green-wire.lua +++ /dev/null @@ -1,14 +0,0 @@ -if data.raw["item"] == nil or - data.raw["item"]["green-wire"] == nil then - data:extend - { - { - type = "item", - name = "green-wire", - icon = Baseless.Image, - icon_size = 1, - stack_size = 1, - subgroup = "dummy-item-subgroup", - }, - } -end diff --git a/prototypes/item/gun.lua b/prototypes/item/gun.lua deleted file mode 100644 index 231d1ae..0000000 --- a/prototypes/item/gun.lua +++ /dev/null @@ -1,5 +0,0 @@ -if CreateItem("gun", { - attack_parameters = Baseless.AttackParameters.Stream(), -}) then - Baseless.AttackParameters.Stream(true) -end diff --git a/prototypes/item/item-with-entity-data.lua b/prototypes/item/item-with-entity-data.lua deleted file mode 100644 index 9303f30..0000000 --- a/prototypes/item/item-with-entity-data.lua +++ /dev/null @@ -1 +0,0 @@ -CreateItem("item-with-entity-data", {}) diff --git a/prototypes/item/item-with-inventory.lua b/prototypes/item/item-with-inventory.lua deleted file mode 100644 index da310dc..0000000 --- a/prototypes/item/item-with-inventory.lua +++ /dev/null @@ -1 +0,0 @@ -CreateItemWithInventory("item-with-inventory", {}) diff --git a/prototypes/item/item-with-label.lua b/prototypes/item/item-with-label.lua deleted file mode 100644 index e61fa26..0000000 --- a/prototypes/item/item-with-label.lua +++ /dev/null @@ -1 +0,0 @@ -CreateItemWithLabel("item-with-label", {}) diff --git a/prototypes/item/item-with-tags.lua b/prototypes/item/item-with-tags.lua deleted file mode 100644 index d85771d..0000000 --- a/prototypes/item/item-with-tags.lua +++ /dev/null @@ -1 +0,0 @@ -CreateItemWithTags("item-with-tags", {}) diff --git a/prototypes/item/item.lua b/prototypes/item/item.lua deleted file mode 100644 index e39773c..0000000 --- a/prototypes/item/item.lua +++ /dev/null @@ -1 +0,0 @@ -CreateItem("item", {}) diff --git a/prototypes/item/mining-tool.lua b/prototypes/item/mining-tool.lua deleted file mode 100644 index bb7a821..0000000 --- a/prototypes/item/mining-tool.lua +++ /dev/null @@ -1 +0,0 @@ -CreateTool("mining-tool", {}) diff --git a/prototypes/item/module.lua b/prototypes/item/module.lua deleted file mode 100644 index 6ea03be..0000000 --- a/prototypes/item/module.lua +++ /dev/null @@ -1,7 +0,0 @@ -if CreateItem("module", { - category = Baseless.ModuleType(), - effect = {}, - tier = 0, -}) then - Baseless.ModuleType(true) -end diff --git a/prototypes/item/rail-planner.lua b/prototypes/item/rail-planner.lua deleted file mode 100644 index 9aa2d5e..0000000 --- a/prototypes/item/rail-planner.lua +++ /dev/null @@ -1,6 +0,0 @@ -if CreateItem("rail-planner", { - curved_rail = "dummy-curved-rail", - straight_rail = "dummy-straight-rail", -}) then - Baseless.Needs.RailEntity = true -end diff --git a/prototypes/item/red-wire.lua b/prototypes/item/red-wire.lua deleted file mode 100644 index 77c056f..0000000 --- a/prototypes/item/red-wire.lua +++ /dev/null @@ -1,14 +0,0 @@ -if data.raw["item"] == nil or - data.raw["item"]["red-wire"] == nil then - data:extend - { - { - type = "item", - name = "red-wire", - icon = Baseless.Image, - icon_size = 1, - stack_size = 1, - subgroup = "dummy-item-subgroup", - }, - } -end diff --git a/prototypes/item/repair-tool.lua b/prototypes/item/repair-tool.lua deleted file mode 100644 index 72babd9..0000000 --- a/prototypes/item/repair-tool.lua +++ /dev/null @@ -1,3 +0,0 @@ -CreateTool("repair-tool", { - speed = 1, -}) diff --git a/prototypes/item/science.lua b/prototypes/item/science.lua deleted file mode 100644 index 65a2c3c..0000000 --- a/prototypes/item/science.lua +++ /dev/null @@ -1,15 +0,0 @@ -if Baseless.Needs.ScienceType then - data:extend - { - { - type = "tool", - name = "dummy-science-pack", - flags = {"hidden"}, - icon = Baseless.Image, - icon_size = 1, - stack_size = 1, - subgroup = "dummy-item-subgroup", - infinite = true, - }, - } -end diff --git a/prototypes/item/selection-tool.lua b/prototypes/item/selection-tool.lua deleted file mode 100644 index 6ca181c..0000000 --- a/prototypes/item/selection-tool.lua +++ /dev/null @@ -1 +0,0 @@ -CreateSelectionTool("selection-tool", {}) diff --git a/prototypes/item/tool.lua b/prototypes/item/tool.lua deleted file mode 100644 index 998af11..0000000 --- a/prototypes/item/tool.lua +++ /dev/null @@ -1 +0,0 @@ -CreateTool("tool", {}) diff --git a/prototypes/item/upgrade-item.lua b/prototypes/item/upgrade-item.lua deleted file mode 100644 index 206b781..0000000 --- a/prototypes/item/upgrade-item.lua +++ /dev/null @@ -1 +0,0 @@ -CreateSelectionTool("upgrade-item", {}) diff --git a/prototypes/map-settings.lua b/prototypes/map-settings.lua index 1ea12b6..1dbd151 100644 --- a/prototypes/map-settings.lua +++ b/prototypes/map-settings.lua @@ -1,6 +1,5 @@ -- Stripped copy of the base mod -data:extend -{ +Baseless.RegisterIfUnique { { type = "map-settings", name = "map-settings", diff --git a/prototypes/other/equipment-grid.lua b/prototypes/other/equipment-grid.lua deleted file mode 100644 index 89900e3..0000000 --- a/prototypes/other/equipment-grid.lua +++ /dev/null @@ -1,14 +0,0 @@ -data:extend -{ - { - type = "equipment-grid", - name = "small-equipment-grid", - equipment_categories = {"dummy-equipment-category"}, - height = 1, - width = 1, - }, - { - type = "equipment-category", - name = "dummy-equipment-category", - }, -} diff --git a/prototypes/other/fluid.lua b/prototypes/other/fluid.lua deleted file mode 100644 index c6f8f84..0000000 --- a/prototypes/other/fluid.lua +++ /dev/null @@ -1,11 +0,0 @@ -if Baseless.Needs.Fluid then - CreatePrototype("fluid", { - base_color = Baseless.Color, - default_temperature = 1, - flow_color = Baseless.Color, - icon = Baseless.Image, - icon_size = 1, - max_temperature = 1, - subgroup = "dummy-item-subgroup", - }) -end diff --git a/prototypes/other/optimized-particle.lua b/prototypes/other/optimized-particle.lua deleted file mode 100644 index 1d074e1..0000000 --- a/prototypes/other/optimized-particle.lua +++ /dev/null @@ -1,8 +0,0 @@ -if Baseless.Needs.Particle then - CreatePrototype("optimized-particle", { - life_time = 2, - pictures = Baseless.AnimationVariations, - render_layer = Baseless.RenderLayer, - render_layer_when_on_ground = Baseless.RenderLayer, - }) -end diff --git a/prototypes/other/tile.lua b/prototypes/other/tile.lua deleted file mode 100644 index eb073ed..0000000 --- a/prototypes/other/tile.lua +++ /dev/null @@ -1,7 +0,0 @@ -CreatePrototype("tile", { - collision_mask = {"ground-tile"}, - layer = 1, - map_color = Baseless.Color, - pollution_absorption_per_second = 0, - variants = Baseless.Transitions, -}) diff --git a/prototypes/other/trivial-smoke.lua b/prototypes/other/trivial-smoke.lua deleted file mode 100644 index 92bd797..0000000 --- a/prototypes/other/trivial-smoke.lua +++ /dev/null @@ -1,13 +0,0 @@ -if data.raw["trivial-smoke"] == nil or - data.raw["trivial-smoke"]["smoke-building"] == nil then - data:extend - { - { - type = "trivial-smoke", - name = "smoke-building", - animation = Baseless.Animation, - duration = 1, - cyclic = true, - }, - } -end diff --git a/prototypes/other/virtual-signal.lua b/prototypes/other/virtual-signal.lua deleted file mode 100644 index b3df9c7..0000000 --- a/prototypes/other/virtual-signal.lua +++ /dev/null @@ -1,41 +0,0 @@ -if data.raw["virtual-signal"] == nil or - data.raw["virtual-signal"]["signal-everything"] == nil then - data:extend - { - { - type = "virtual-signal", - name = "signal-everything", - icon = Baseless.Image, - icon_size = 1, - subgroup = "dummy-item-subgroup", - }, - } -end - -if data.raw["virtual-signal"] == nil or - data.raw["virtual-signal"]["signal-anything"] == nil then - data:extend - { - { - type = "virtual-signal", - name = "signal-anything", - icon = Baseless.Image, - icon_size = 1, - subgroup = "dummy-item-subgroup", - }, - } -end - -if data.raw["virtual-signal"] == nil or - data.raw["virtual-signal"]["signal-each"] == nil then - data:extend - { - { - type = "virtual-signal", - name = "signal-each", - icon = Baseless.Image, - icon_size = 1, - subgroup = "dummy-item-subgroup", - }, - } -end diff --git a/prototypes/required.lua b/prototypes/required.lua new file mode 100644 index 0000000..f2d0ba1 --- /dev/null +++ b/prototypes/required.lua @@ -0,0 +1,49 @@ +Baseless.RegisterIfNew { + Baseless.Make.Base("trigger-target-type", "ground-unit", {}), + Baseless.Make.DamageType("physical", {}), + Baseless.Make.DamageType("impact", {}), + Baseless.Make.EquipmentGrid("small-equipment-grid", {}), + Baseless.Make.Item(nil, "copper-cable", {}), + Baseless.Make.Item(nil, "red-wire", {}), + Baseless.Make.Item(nil, "green-wire", {}), + Baseless.Make.RecipeCategory("crafting", {}), + Baseless.Make.ResourceCategory("basic-solid", {}), + Baseless.Make.TrivialSmoke("smoke-building", {}), + Baseless.Make.VirtualSignal("signal-everything", {}), + Baseless.Make.VirtualSignal("signal-anything", {}), + Baseless.Make.VirtualSignal("signal-each", {}), +} + +if Baseless.RegisterIfNew( + Baseless.Make.ItemSubGroup("other", "dummy-item-group", {}) +) then + Baseless.RegisterIfNew( + Baseless.Make.ItemGroup() + ) +end + +-- Requires at least one tile that is walkable and not minable +for _,tile in pairs(data.raw["tile"] or {}) do + if tile.minable == nil then + for _,mask in pairs(tile.collision_mask or {}) do + if mask == "ground-tile" then + goto after_tile + end + end + end +end +Baseless.RegisterIfNew { + Baseless.Make.Tile(nil, { + collision_mask = {"ground-tile"}, + }), +} +::after_tile:: + +-- Deprecated prototypes +Baseless.RegisterIfUnique { + Baseless.Make.Entity("decorative", nil, {}), + Baseless.Make.Entity("leaf-particle", "leaf-particle-for-migration", {}), + Baseless.Make.Entity("particle", "particle-for-migration", {}), + Baseless.Make.Smoke("smoke", "smoke-for-migration", {}), + Baseless.Make.Tool("mining-tool", "mining-tool-for-migration", {}), +} diff --git a/thumbnail.png b/thumbnail.png new file mode 100644 index 0000000..f6c681e Binary files /dev/null and b/thumbnail.png differ