define ship roles via added modules and allow multiple weapons

This commit is contained in:
2026-06-01 22:57:53 +02:00
parent f363f7a67c
commit 9d0a60a93b
31 changed files with 873 additions and 407 deletions

View File

@@ -34,7 +34,7 @@ threat_cost = 3.0
fill_color = "#FF4040"
glyph = "W"
[module.combat]
[module.weapon]
multiplied_damage_formula = "1.0 + 0.15 * x"
[[module]]
@@ -49,3 +49,46 @@ glyph = "E"
[module.movement]
added_speed_formula = "0.5 * x"
[[module]]
id = "laser_cannon"
surface_mask = ["O"]
materials = [{item = "iron_ingot", amount = 1}]
player_production_level = 1
production_time_seconds = 5
threat_cost = 5.0
fill_color = "#FF8040"
glyph = "L"
[module.weapon]
damage_formula = "2"
attack_range_formula = "5"
attack_rate_formula = "2.0"
[[module]]
id = "salvage_bay_module"
surface_mask = ["OO"]
materials = [{item = "iron_ingot", amount = 2}]
player_production_level = 1
production_time_seconds = 5
threat_cost = 0.0
fill_color = "#AACC44"
glyph = "Sv"
[module.salvage]
collection_range_formula = "50"
cargo_capacity_formula = "10"
[[module]]
id = "repair_tool_module"
surface_mask = ["O"]
materials = [{item = "circuit_board", amount = 2}]
player_production_level = 1
production_time_seconds = 5
threat_cost = 0.0
fill_color = "#66CCFF"
glyph = "Rp"
[module.repair]
repair_rate_formula = "5 + x"
repair_range_formula = "80"

View File

@@ -2,6 +2,7 @@
id = "fighter"
available_from_start = true
layout = ["XOX", "OOO", "XOX"]
default_modules = [{type = "laser_cannon", x = 1, y = 1, rotation = "east"}]
[ship.schematic]
materials = [{item = "iron_ingot", amount = 3}, {item = "circuit_board", amount = 1}]
@@ -24,11 +25,6 @@ max_rotation_speed_formula = "6.28"
[ship.sensor]
sensor_range_formula = "15"
[ship.combat]
damage_formula = "2"
attack_range_formula = "5"
attack_rate_formula = "2.0"
[ship.loot]
scrap_drop = 2
@@ -38,6 +34,7 @@ scrap_drop = 2
id = "sniper"
available_from_start = true
layout = ["XOOX", "OOOO", "XOOX"]
default_modules = [{type = "laser_cannon", x = 1, y = 1, rotation = "east"}]
[ship.schematic]
materials = [{item = "iron_ingot", amount = 3}, {item = "circuit_board", amount = 1}]
@@ -60,11 +57,6 @@ max_rotation_speed_formula = "3.14"
[ship.sensor]
sensor_range_formula = "25"
[ship.combat]
damage_formula = "10"
attack_range_formula = "20"
attack_rate_formula = "0.5"
[ship.loot]
scrap_drop = 2
@@ -74,6 +66,7 @@ scrap_drop = 2
id = "gunship"
available_from_start = true
layout = ["XOOOX", "OOOOO", "OOOOO", "XOOOX"]
default_modules = [{type = "laser_cannon", x = 1, y = 1, rotation = "east"}]
[ship.schematic]
materials = [{item = "iron_ingot", amount = 3}, {item = "circuit_board", amount = 1}]
@@ -96,11 +89,6 @@ max_rotation_speed_formula = "3.14"
[ship.sensor]
sensor_range_formula = "20"
[ship.combat]
damage_formula = "1"
attack_range_formula = "10"
attack_rate_formula = "5"
[ship.loot]
scrap_drop = 2
@@ -132,10 +120,6 @@ max_rotation_speed_formula = "6.28"
[ship.sensor]
sensor_range_formula = "250"
[ship.salvage]
collection_range = 50
cargo_capacity = 10
[ship.loot]
scrap_drop = 2
@@ -166,9 +150,5 @@ max_rotation_speed_formula = "6.28"
[ship.sensor]
sensor_range_formula = "250"
[ship.repair]
repair_rate_formula = "5 + x"
repair_range_formula = "80"
[ship.loot]
scrap_drop = 2

View File

@@ -141,26 +141,29 @@ outline = "#201a14"
# -----------------------------------------------------------------------------
# Ships
#
# Ships are drawn as oriented triangles/arrows. Color is keyed to role, not
# schematic (architecture.md, "Layer Order").
# Ships are drawn as oriented triangles/arrows. Color is keyed to schematic id.
# -----------------------------------------------------------------------------
[ships.player_combat]
[ships.fighter]
fill = "#3366ff"
outline = "#ffffff"
[ships.salvage]
[ships.sniper]
fill = "#3366ff"
outline = "#ffffff"
[ships.gunship]
fill = "#3366ff"
outline = "#ffffff"
[ships.salvage_ship]
fill = "#33cc66"
outline = "#ffffff"
[ships.repair]
[ships.repair_ship]
fill = "#66ccff"
outline = "#ffffff"
[ships.enemy]
fill = "#cc3333"
outline = "#ffffff"
# -----------------------------------------------------------------------------
# Laser beams (REQ-SHP-FIRING-BEAM)
# -----------------------------------------------------------------------------