# Ship damage (design 17, step 35). Read at startup by the game and the server
# (src/model/ships/ShipDamage.cpp).
#
# Shields soak every hit until a hit empties them. Then they collapse: no recharge for the reboot
# time, after which they refill from nothing at the normal rate. Each working shield generator
# brings back only its own bar, scaled by how damaged it is. While they're down, hits land on the
# blocks they strike, and blocks keep their damage.
#
# [shields Settings]
#   reboot         s the generators stay dark after a collapse
#
# [states Settings] A block's damage state, from the share of its health left:
#   scuffed        below this it is scuffed (scorch marks, works fully)
#   damaged        below this it is damaged (cracks, sparks, half output)
#   critical       below this it is critical (deep cracks, smoke, a quarter of output)
#   wrecked share  a wrecked tech block (a burnt shell that still fills its cell) takes this share
#                  of its health more before it is destroyed. Plain blocks skip wrecked.
#   shown          the nearest damaged blocks drawn with cracks
#
# [<kind> Weapon] What each kind of weapon does against shields and against blocks:
#   shields        share of its damage the shields take
#   blocks         share of its damage the block it strikes takes
#   carry          share of what is left after a block breaks that carries on along the shot into
#                  the next block (overpenetration)
#   reach          m the shot carries on through the ship, at most
#   radius         m (explosive): blocks within it take damage, less further from the burst
#
# Laser cannons, laser turrets and mining lasers are energy weapons; missiles and bombs explosive.
# Kinetic weapons (mass drivers, flak) come later; their row is ready for them.
#
# [systems Settings] Systems under damage (design 17.4). A damaged system block gives half its
# output, a critical one a quarter, a wrecked one nothing. A critical one also cuts out now and then:
#   cut every      s between cut-outs of one critical block, on average
#   cut min, max   s a cut-out lasts
#   blow chance    per second: the odds a critical reactor or fuel cell blows
#   blow on hit    the odds it blows when struck while critical
#   blow damage    its burst, to every block within an explosive's radius
#
# [fire Settings] Fires aboard ships (design 17.4). A burning block needs a face on a room whose
# air is held in: venting the room puts it out.
#   tick           s between steps of the fires
#   ignite         the odds a hit on a reactor or fuel cell sets it alight
#   spread         per second, to a face neighbour (times both blocks' flammability)
#   burn           damage a second to the burning block
#   max burning    blocks alight on one ship at most
#   budget         burning blocks looked at each step, over every ship
#   suppress       per second: a fire suppressor putting out each fire in the rooms it opens onto
#   reach, cone    m and degrees: what an extinguisher's spray reaches
#   spray          per second: each burning block in the spray going out
#
# [repair Settings] Repair (design 17.5). The welder raises a damaged block a state at a time:
#   weld seconds   s a pass takes
#   plain cost     what a pass on a plain block takes (KEY COUNT, ...)
#   tech cost      and on a tech block
#   patch kit      share of the hull pool a patch kit patches
#   drydock block  credits per point of block damage the station's drydock mends
#   drydock wreck  credits per burnt-out part it rebuilds (on top of the hull's, prices.txt `repair`)
#
# [flammability Blocks] How readily a block catches, by name (0 or not listed: never).
#
# [health Blocks] The health of tech blocks, by the name the game shows: `Shield Generator = 260`.
# A block not listed keeps the plain rule (30 points per second it takes to break by hand). A
# structure of several cells has one health for all of them.

[shields Settings]
reboot = 6

[states Settings]
scuffed = 0.75
damaged = 0.5
critical = 0.25
wrecked share = 0.5
shown = 48

[energy Weapon]
shields = 1
blocks = 1
carry = 0.5
reach = 4
radius = 0

[kinetic Weapon]
shields = 0.5
blocks = 1
carry = 0.85
reach = 10
radius = 0

[explosive Weapon]
shields = 0.5
blocks = 1
carry = 0
reach = 0
radius = 3

[health Blocks]
Cockpit = 360
Corvette Core = 720
Pilot Chair = 160
Reactor = 320
Shield Generator = 260
Life Support = 220
Gravity Generator = 220
Thruster = 260
Large Engine = 520
Maneuvering Thrusters = 240
Laser Cannon = 340
Mining Laser = 340
Laser Turret = 220
Turret Cockpit = 420
Turret Cannon = 240
Missile Rack = 180
Flare Launcher = 150
Bomb Bay = 200
Fuel Cell = 150
Cargo Pod = 200
Warp Drive = 300
Interdictor = 300

[systems Settings]
cut every = 8
cut min = 1
cut max = 2
blow chance = 0.03
blow on hit = 0.12
blow damage = 240

[fire Settings]
tick = 0.25
ignite = 0.35
spread = 0.35
burn = 6
max burning = 128
budget = 256
suppress = 1.5
reach = 5
cone = 35
spray = 2.5

[repair Settings]
weld seconds = 2
plain cost = iron_plate 1
tech cost = iron_plate 2, copper_wire 1
patch kit = 0.25
drydock block = 0.5
drydock wreck = 40

# Salvage and wrecks (design 16, step 35d).
#   explode keep   share of an exploded ship's blocks left as a wreck (its biggest piece)
#   tear, burn     a disabled ship's wreck: share of hull plates torn off, of parts burnt out
#   life           s of play an untouched wreck lasts; it never goes with a player within `near` m
#   cutter         how much faster the salvage cutter takes a ship's block apart than a hand
[salvage Settings]
explode keep = 0.4
tear = 0.12
burn = 0.78
life = 10800
near = 1200
cutter = 3

[flammability Blocks]
Reactor = 1
Fuel Cell = 1.5
Cargo Pod = 0.8
Crate = 1
Barrel = 1.2
Console = 0.6
Server Rack = 0.6
Bed = 1
Chair = 0.8
Table = 0.8
Shelf = 0.8
Locker = 0.5
Planks = 1.2
Wood Log = 1
Life Support = 0.4
Gravity Generator = 0.3
Shield Generator = 0.3
Power Cable = 0.5
Battery Bank = 0.8
Deck Plate = 0.15
Wall Panel = 0.3
