Respawn-reset audit: valve restore + peer smoke cleanup (both binary-grounded)

Operator reports audited vs the binary (full matrix in RESPAWN_REARM_PLAN
addendum):
- VALVES (real gap): Condenser reset @004ae534 was missing from the decomp
  export -- raw disasm shows it chains HEATSINK (coolant refill runs; the
  old body chained HeatableSubsystem per the stale TCP shard) then, respawn-
  side, resets valveState to detent 1 and restores massScale from
  refrigerationFactor.  Mech::Reset now also runs the binary's tail call
  (@0049f788 BTRecomputeCondenserValves) so flow fractions rebuild from the
  reset detents.  Bench: detent 5 -> death -> "[respawn] Condenser1 valve
  detent 5 -> 1".
- #129 SMOKE (real gap, peers-only): the replicant un-wreck edge rebuilt
  the model without the @004d0c14 per-entity effect cleanup, so the
  observer's last 10s wreck-plume window rode the teleport onto the fresh
  mech.  BTStopEntityPfx now runs on the edge; bench shows no plume line
  after any un-wreck until the next death.
- AUTHENTIC (no fix): weapon->generator taps persist (@004b0e6c only
  resolves the link) and MFD display/control modes persist (mapper vtables
  0050f45c/0051e440 slots 8-11 = plain root bodies, read from the exe).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
Joe DiPrima
2026-08-04 16:14:10 -05:00
co-authored by Claude Fable 5
parent b6656e35c5
commit 26ab2fee3a
5 changed files with 101 additions and 11 deletions
+28 -10
View File
@@ -359,22 +359,40 @@ Condenser::~Condenser()
#endif
//###########################################################################
// ResetToInitialState -- Condenser (HEAT.TCP)
// ResetToInitialState -- Condenser
//
// RE-TRANSCRIBED FROM THE BINARY (respawn-reset audit 2026-08-04; the function
// is MISSING from the Ghidra export -- disassembled raw, tools/disas2.py
// 0x4ae534 0x60). The old body chained HeatableSubsystem (temp+heatLoad only,
// per the stale HEAT.TCP shard) -- the binary chains HEATSINK (call 0x4ad760),
// so the coolant refill DOES run for a condenser; then, RESPAWN-side only:
//
// test esi, esi ; je ... -> if (powered) {
// [this+0x1d0] = 1 -> valveState = 1 (default detent --
// the pod RESETS every coolant valve)
// eax = [this+0x1d8]; [0x160] = eax -> massScale = refrigerationFactor
// (restore the refrigeration output) }
//
// Mech::Reset's tail then re-runs BTRecomputeCondenserValves (@0049f788), so
// the flow fractions rebuild from the reset detents (mech4.cpp). This is the
// operator-reported "coolant valves survive a respawn" gap [was T3, now T1].
//
void
Condenser::ResetToInitialState(Logical /*powered*/)
Condenser::ResetToInitialState(Logical powered)
{
HeatableSubsystem::ResetToInitialState(True);
HeatSink::ResetToInitialState(powered); // call 0x4ad760
if (powered)
{
if (getenv("BT_DEATH_LOG") && valveState != 1)
DEBUG_STREAM << "[respawn] " << GetName() << " valve detent "
<< valveState << " -> 1 (authentic @004ae534 restore)\n" << std::flush;
valveState = 1; // @0x1D0 = 1
massScale = refrigerationFactor; // @0x160 = @0x1D8
}
}
//
// DeathReset (Gitea #55): the respawn sweep's entry for a Condenser -- a coolant
// loop's valve. NOTE the body above chains HeatableSubsystem's (temperature +
// heatLoad) and so does NOT run HeatSink's coolant refill, even though Condenser
// derives from HeatSink. That mirrors the existing reconstruction; whether the
// binary's Condenser reset also restores the VALVE SETTING is not established from
// the decomp yet, so valve detents may still persist across a respawn.
// [T3 -- do NOT claim valves are fixed; tracked on the issue.]
// DeathReset (Gitea #55): the respawn sweep's entry for a Condenser.
//
void
Condenser::DeathReset(int reset_command)