Build the full combat-system experiment from its spec, no slices deferred.
combat-core — pure, headless, deterministic engine (the single source of truth):
- One combined Vigor pool (HP+mana+stamina merged) with the two-axis
(fill, ceiling) cost model; offense spends survival.
- Stagger cascade (absorbed/dazed/unconscious/dead), capacity = current fill,
ceiling collapse via fatigue as the real loss condition; revive-on-recovery.
- Unified ability model (skills == spells) with the delivery+effects+potency+
targets cost composer and a full effect library (fill/ceiling damage, DoT/HoT,
regen-sabotage, fatigue-amp, mitigation buff/debuff, recovery).
- Ordered mitigation pipeline, config-driven con curve, competency/fizzle/resist,
loadout/memorization, active-defense windows.
- Symmetric actors; pluggable controllers (SwingOnCooldown, ScriptedPlayer{skill},
HoldAndPunish). Fixed-tick loop with the canonical within-tick resolution order;
decisions are simultaneous within a tick so mirror matches are fair.
- Determinism is load-bearing: vendored order-independent RNG fork (+ integer
chance_bp so no f64 touches the hot path) and integer fixed-point magnitudes
with banker's rounding. 48 tests incl. bit-reproducible event-log integration.
combat-sim — batch harness: loads the config "table", runs con-tier x skill and
archetype sweeps (tens of thousands of fights), exports per-fight CSV, an
aggregated summary, and one fight's full event log.
analysis — pandas/matplotlib layer: difficulty curve, duration tent, anti-turtle
guardrail, stagger frequency, and one fight's fill/ceiling time series.
The sim did its job: the first default numbers produced a one-tick cliff and 82%
mutual-KO draws and surfaced the spec's deepest risk live (a poke skill strictly
worse than free auto-attack, so auto-only out-won the full kit). Tuning the table
moved it to the intended shape — duration tent peaking ~22s at even con, a
monotone skill->win-rate gradient (auto ~3% -> skill100 44% at even con), and a
green anti-turtle guardrail. That sim->measure->tune loop is the deliverable.
Own Cargo workspace, fully decoupled from the root reikhelm workspace.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
187 lines
5 KiB
JSON
187 lines
5 KiB
JSON
{
|
|
"_comment": "The combat 'table' (spec §11). Magnitudes are displayed units; ratios/percentages are basis points (10000 = 1.0 = 100%); durations are ticks. Editing this file is the primary balancing act. tick_rate ticks = 1 second.",
|
|
|
|
"tick_rate": 10,
|
|
"damage_variance_bp": 1500,
|
|
|
|
"regen": {
|
|
"dazed_regen_bp": 5000,
|
|
"floor_per_sec": 1
|
|
},
|
|
|
|
"stagger": {
|
|
"daze_threshold_bp": 10000,
|
|
"unconscious_threshold_bp": 15000,
|
|
"daze_duration": 8,
|
|
"revive_daze": 12,
|
|
"fatigue_ratio_bp": 2000
|
|
},
|
|
|
|
"competency": {
|
|
"level_per_point_bp": 200
|
|
},
|
|
|
|
"fizzle": {
|
|
"base_bp": 200,
|
|
"per_gap_bp": 150,
|
|
"max_bp": 9000
|
|
},
|
|
|
|
"cost_model": {
|
|
"base_fill_self": 0,
|
|
"base_fill_touch": 1,
|
|
"base_fill_melee": 1,
|
|
"base_fill_projectile": 2,
|
|
"base_fill_beam": 3,
|
|
"base_fill_aoe": 4,
|
|
"fatigue_ratio_bp": 2000,
|
|
"difficulty_per_fill_bp": 10000
|
|
},
|
|
|
|
"con_curve": [
|
|
{ "delta": -8, "mult_bp": 4000 },
|
|
{ "delta": -5, "mult_bp": 6000 },
|
|
{ "delta": -2, "mult_bp": 8500 },
|
|
{ "delta": 0, "mult_bp": 10000 },
|
|
{ "delta": 2, "mult_bp": 11500 },
|
|
{ "delta": 5, "mult_bp": 15000 },
|
|
{ "delta": 8, "mult_bp": 19000 }
|
|
],
|
|
|
|
"abilities": [
|
|
{
|
|
"id": "auto_attack",
|
|
"name": "Auto-Attack",
|
|
"school": "martial",
|
|
"delivery": "melee",
|
|
"effects": [ { "kind": "fill_damage", "magnitude_bp": 800, "cost_fill": 0 } ],
|
|
"cooldown": 10,
|
|
"cost_override": { "fill": 0, "fatigue": 1 }
|
|
},
|
|
{
|
|
"id": "quick_jab",
|
|
"name": "Quick Jab",
|
|
"school": "martial",
|
|
"delivery": "melee",
|
|
"effects": [ { "kind": "fill_damage", "magnitude_bp": 1700, "cost_fill": 6 } ],
|
|
"cooldown": 6
|
|
},
|
|
{
|
|
"id": "heavy_strike",
|
|
"name": "Heavy Strike",
|
|
"school": "martial",
|
|
"delivery": "melee",
|
|
"effects": [ { "kind": "fill_damage", "magnitude_bp": 4500, "cost_fill": 26 } ],
|
|
"cooldown": 22
|
|
},
|
|
{
|
|
"id": "fireball",
|
|
"name": "Fireball",
|
|
"school": "invocation",
|
|
"delivery": "projectile",
|
|
"effects": [ { "kind": "fill_damage", "magnitude_bp": 3500, "cost_fill": 24 } ],
|
|
"potency_bp": 10000,
|
|
"cast_time": 12,
|
|
"cooldown": 20
|
|
},
|
|
{
|
|
"id": "curse_of_weariness",
|
|
"name": "Curse of Weariness",
|
|
"school": "affliction",
|
|
"delivery": "projectile",
|
|
"effects": [ { "kind": "ceiling_damage", "magnitude_bp": 1400, "cost_fill": 16 } ],
|
|
"cast_time": 8,
|
|
"cooldown": 40
|
|
},
|
|
{
|
|
"id": "venom",
|
|
"name": "Venom",
|
|
"school": "affliction",
|
|
"delivery": "touch",
|
|
"effects": [ { "kind": "dot", "per_tick_bp": 250, "duration": 20, "cost_fill": 12 } ],
|
|
"cooldown": 30
|
|
},
|
|
{
|
|
"id": "enervate",
|
|
"name": "Enervate",
|
|
"school": "affliction",
|
|
"delivery": "projectile",
|
|
"effects": [ { "kind": "regen_sabotage", "reduce_bp": 6000, "duration": 30, "cost_fill": 10 } ],
|
|
"cast_time": 6,
|
|
"cooldown": 35
|
|
},
|
|
{
|
|
"id": "second_wind",
|
|
"name": "Second Wind",
|
|
"school": "restoration",
|
|
"delivery": "self_cast",
|
|
"effects": [ { "kind": "recovery", "magnitude_bp": 3000, "cost_fill": 3 } ],
|
|
"cooldown": 45
|
|
},
|
|
{
|
|
"id": "mend",
|
|
"name": "Mend",
|
|
"school": "restoration",
|
|
"delivery": "self_cast",
|
|
"effects": [ { "kind": "hot", "per_tick_bp": 200, "duration": 15, "cost_fill": 6 } ],
|
|
"cast_time": 10,
|
|
"cooldown": 45
|
|
},
|
|
{
|
|
"id": "guard",
|
|
"name": "Guard",
|
|
"school": "martial",
|
|
"delivery": "self_cast",
|
|
"effects": [ { "kind": "mitigation_buff", "stage": "active_defense", "amount_bp": 8000, "duration": 3, "cost_fill": 0 } ],
|
|
"cooldown": 15,
|
|
"cost_override": { "fill": 0, "fatigue": 2 }
|
|
}
|
|
],
|
|
|
|
"stat_blocks": {
|
|
"duelist": {
|
|
"name": "Duelist",
|
|
"team": 0,
|
|
"level": 10,
|
|
"max_vigor": 120,
|
|
"regen_idle_per_sec": 12,
|
|
"regen_combat_per_sec": 6,
|
|
"armor_bp": 1500,
|
|
"competency": { "martial": 50, "restoration": 30 },
|
|
"loadout": ["auto_attack", "quick_jab", "heavy_strike", "second_wind", "guard"]
|
|
},
|
|
"battlemage": {
|
|
"name": "Battlemage",
|
|
"team": 0,
|
|
"level": 10,
|
|
"max_vigor": 100,
|
|
"regen_idle_per_sec": 12,
|
|
"regen_combat_per_sec": 7,
|
|
"armor_bp": 500,
|
|
"competency": { "invocation": 50, "affliction": 40, "restoration": 25, "martial": 15 },
|
|
"loadout": ["auto_attack", "fireball", "curse_of_weariness", "second_wind", "guard"]
|
|
},
|
|
"golem": {
|
|
"name": "Golem",
|
|
"team": 1,
|
|
"level": 10,
|
|
"max_vigor": 260,
|
|
"regen_idle_per_sec": 6,
|
|
"regen_combat_per_sec": 3,
|
|
"armor_bp": 3500,
|
|
"competency": { "martial": 40 },
|
|
"loadout": ["auto_attack", "heavy_strike"]
|
|
},
|
|
"rat": {
|
|
"name": "Rat",
|
|
"team": 1,
|
|
"level": 8,
|
|
"max_vigor": 45,
|
|
"regen_idle_per_sec": 16,
|
|
"regen_combat_per_sec": 9,
|
|
"armor_bp": 0,
|
|
"competency": { "martial": 20 },
|
|
"loadout": ["auto_attack", "quick_jab"]
|
|
}
|
|
}
|
|
}
|