Files
windroost/data/mvp_battle_rules.json
T
wushenghua d6b72043e4 feat: prove five pacing profiles and calibrate offline payout
AGENTS.md requires a milestone to prove five play profiles with explicit
decision timestamps. The chapter simulator previously had only passive/active.
tools/pacing_profiles.py now runs five genuinely different behaviours (normal,
active, efficient, adversarial, returning) and records per-node arrival times,
every decision timestamp, longest no-decision gap, active-input share,
failures and offline efficiency. data/pacing_profiles.json holds the evidence;
tools/check_pacing_profiles.py gates it; PRODUCTION/40 documents the results
and the honest findings.

The profiling exposed a real bug I introduced: the offline gold rate (0.02, a
value I had picked without a contract basis) paid 19008 gold for 8h, leveling
the first hero to Lv.17 when a normal clear ends at Lv.2-4. tools/tune_offline.py
scans rates; 0.001 pays 950 gold (~Lv.4) and keeps returning players in range.
The rate now lives in mvp_battle_rules.json progression and is read by both the
Godot ProfileStore and the Python simulator, so the two cannot drift. The p3b
test derives its expected values from the same shared rate.

Two honest findings are recorded, not hidden: efficient is slower than active
because weakness windows are not yet a settlement multiplier (tracked in
PRODUCTION/39), and concentrated upgrades outperform spread ones in the CH
cost curve. tools/run_p2_checks.sh now runs 21 gates; all pass.
2026-11-17 14:23:34 +08:00

152 lines
3.9 KiB
JSON

{
"schema": 1,
"purpose": "Shared P3a/P2 combat rule and balance table. Both the paper runner (tools/mvp_validation_sim.py) and the Godot runtime adapter (p2_godot_sample/scripts/battle_sim.gd) MUST read this file. No engine may hardcode these numbers. Changing a value here changes the numeric contract and invalidates the frozen reference in data/mvp_validation_seed_reference.json.",
"authority": "BATTLE_RULES_AND_NUMERIC_SPEC.md section 6",
"tick_seconds": 0.1,
"seed_derivation": {
"algorithm": "sha256",
"input_format": "{scenario_id}:{seed}",
"prefix_bytes": 6,
"divisor": 281474976710656,
"comment": "6 bytes = 48 bits, exactly representable as a float64 in every engine. Both engines must derive the same efficiency factor bit for bit."
},
"constants": {
"armor_base": 100.0,
"weak_multiplier": 1.5,
"efficiency_min": 0.86,
"efficiency_range": 0.28,
"click_base": 20.0,
"click_roster_multiplier": 0.45,
"burst_base": 180.0,
"burst_roster_multiplier": 1.2,
"ultimate_atk_multiplier": 4.5
},
"heroes": {
"H01": {
"base_atk": 10.0,
"base_dps": 8.0,
"signature_dps": 4.0,
"counters": [
"break",
"single"
]
},
"H02": {
"base_atk": 14.0,
"base_dps": 12.0,
"signature_dps": 5.0,
"counters": [
"break",
"single"
]
},
"H03": {
"base_atk": 16.0,
"base_dps": 13.0,
"signature_dps": 5.5,
"counters": []
},
"H04": {
"base_atk": 11.0,
"base_dps": 9.0,
"signature_dps": 3.0,
"counters": []
},
"H05": {
"base_atk": 15.0,
"base_dps": 13.0,
"signature_dps": 5.0,
"counters": []
},
"H06": {
"base_atk": 12.0,
"base_dps": 10.0,
"signature_dps": 4.5,
"counters": []
}
},
"enemies": {
"E-R1-F1-V1": {
"kind": "normal",
"hp": 480.0,
"armor": 1.0,
"shield": 0.0,
"weak_tag": "aoe",
"rebuild_at": [],
"rebuild_amount": 0.0
},
"E-R1-F3-V1": {
"kind": "elite",
"hp": 1300.0,
"armor": 3.0,
"shield": 60.0,
"weak_tag": "break",
"rebuild_at": [
6.0,
12.0
],
"rebuild_amount": 220.0
},
"E-R1-F4-V1": {
"kind": "elite_support",
"hp": 450.0,
"armor": 1.0,
"shield": 0.0,
"weak_tag": "sustain",
"rebuild_at": [],
"rebuild_amount": 0.0
},
"B-R1-01": {
"kind": "boss",
"hp": 1500.0,
"armor": 5.0,
"shield": 200.0,
"weak_tag": "break",
"rebuild_at": [
8.0,
16.0
],
"rebuild_amount": 420.0
}
},
"reward_ids": {
"P3A-N01-AUTO": "REWARD-R1-C01-N01",
"P3A-N03-SEMI": "REWARD-R1-C01-N03",
"P3A-N10-MANUAL_WIN": "DROP-R1-BOSS-01",
"P3A-N10-MANUAL_LOSS": "REWARD-R1-C01-N10"
},
"reward_amounts": {
"REWARD-R1-C01-N01": {
"gold": 30,
"crystal": 0
},
"REWARD-R1-C01-N03": {
"gold": 50,
"crystal": 0
},
"DROP-R1-BOSS-01": {
"gold": 100,
"crystal": 5
},
"REWARD-R1-C01-N10": {
"gold": 0,
"crystal": 0
}
},
"progression": {
"initial_level": 1,
"dps_per_level_ratio": 0.25,
"upgrade_base_cost": 120,
"upgrade_cost_growth": 1.15,
"comment": "Hero DPS at level n is base_dps * (1 + dps_per_level_ratio * (n - initial_level)). The roster bonus is the sum of the per-hero gains and is passed into create_state. Upgrade cost grows geometrically per purchased level.",
"offline_gold_per_dps_second": 0.001,
"offline_calibration_note": "8h capped claim at 33 starting DPS pays 950 gold -> about 7 upgrades -> H01 Lv.4, keeping returning players in the Lv.3-6 range instead of Lv.17. Calibrated by tools/tune_offline.py."
},
"evaluation_order": [
"input_events",
"shield_rebuild",
"visible_signature_damage",
"roster_dps_damage"
]
}