Mech milestone: reconstruct NameFilter (helper 3/3) -- helpers phase complete
NameFilter is the Mech's mechNameFilter (@0x36c), a small fixed debounce record the ctor initialises. Reconstructed from FUN_00435a7c: a 10-word (0x28) struct, Initialize() sets [2]=1 / [8]=[9]=-1 / rest 0 exactly. Header-only. Field semantics unresolved (only caller is Initialize; reader is the unbuilt HUD) -- names best-effort, but size + init values are binary-exact, which is all the Mech layout + ctor need. All 3 missing embedded helper classes now reconstructed + compile-verified under BC4.52 (AlarmIndicator, SequenceController struct+Init, NameFilter). MECH-LAYOUT.md step 1 marked done. Next: MechSubsystem base + the subsystem roster, then finalize MECH.HPP (probe sizeof==0x854), then the ctor + segment-table walk. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,49 @@
|
||||
#if !defined(NAMEFILT_HPP)
|
||||
# define NAMEFILT_HPP
|
||||
|
||||
//##########################################################################
|
||||
//########################### NameFilter #############################
|
||||
//##########################################################################
|
||||
//
|
||||
// The Mech's `mechNameFilter` (@0x36c). A small fixed debounce/hysteresis
|
||||
// record; the Mech ctor Initialize()s it and the (not-yet-reconstructed) HUD
|
||||
// path reads it. Absent from the 4.10 archive; BT411 mis-proxied it as a
|
||||
// no-op running-average. See NAMEFILT.NOTES.md.
|
||||
//
|
||||
// Layout + Initialize() values are recovered exactly from the shipped binary
|
||||
// (FUN_00435a7c); the field SEMANTICS are not yet resolved (the only caller
|
||||
// in the mech family is Initialize()), so the members carry their known
|
||||
// init values with best-effort names.
|
||||
//
|
||||
class NameFilter
|
||||
{
|
||||
public:
|
||||
void
|
||||
Initialize()
|
||||
{
|
||||
value0 = 0; // [0]
|
||||
value1 = 0; // [1]
|
||||
count = 1; // [2]
|
||||
sample0 = 0; // [3]
|
||||
sample1 = 0; // [4]
|
||||
sample2 = 0; // [5]
|
||||
sample3 = 0; // [6]
|
||||
sample4 = 0; // [7]
|
||||
candidateID = -1; // [8] (invalid id)
|
||||
confirmedID = -1; // [9] (invalid id)
|
||||
}
|
||||
|
||||
public:
|
||||
int value0;
|
||||
int value1;
|
||||
int count;
|
||||
int sample0;
|
||||
int sample1;
|
||||
int sample2;
|
||||
int sample3;
|
||||
int sample4;
|
||||
int candidateID;
|
||||
int confirmedID;
|
||||
};
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user