MP: authentic update-record deadbands streamed from the model record (task #3)
Binary ctor @0x4a26a7-0x4a26ef: mech+0x768/76c/770 <- raw record words 0x26/0x27/0x28 (UpdatePositionDiffrence / UpdateTurnVelocityDiffrence / UpdateTurnDegreeDiffrence x pi/180 [const @0x4a2d44]). Read at RAW record offsets -- the Mech__ModelResource struct is layout-skewed (field98 gave -1.5 where the record holds 0.3; audit filed as task #4, also explains the old forwardCycleRate "floor 25" hack). Sender triggers now use the authored constants: pos-deadband type 0, quat-Y delta + yaw-rate delta + stopped-turn edge type 4 (binary @0x4aad35/@0x4aac2b/@0x4aac6c). Verified 2-node: madcat streams 0.3/0.045/3deg, type-4 spam gone, walking replicant clean. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Fable 5
parent
e8b9f71025
commit
a652ddcdbc
@@ -1267,9 +1267,19 @@ Mech::Mech(
|
||||
Wword(0x15a) = (int)(model->lookRightAngle * DegreesToRadians); // +0x54
|
||||
Wword(0x15b) = (int)(model->lookFrontAngle * DegreesToRadians); // +0x58
|
||||
Wword(0x15c) = (int)(model->lookBackAngle * DegreesToRadians); // +0x5c
|
||||
Wword(0x1dc) = (int)(model->fieldA0 * DegreesToRadians);
|
||||
Wword(0x1db) = model->field9c;
|
||||
Wword(0x1da) = model->field98;
|
||||
// The update-record deadbands, read at the RAW record offsets the binary
|
||||
// itself uses ([esi+0x98/0x9c/0xa0], disasm @0x4a26a7-0x4a26ef) -- the
|
||||
// Mech__ModelResource struct fieldXX members are LAYOUT-SKEWED (audit
|
||||
// task: struct field98 read -1.5 where raw word 0x26 holds 0.3). A
|
||||
// resource record is a byte blob, so word-indexed reads are the correct
|
||||
// idiom (not the object databinding trap).
|
||||
updateTurnAngleDeadband = ((Scalar *)model)[0x28] * DegreesToRadians; // @0x770 <- UpdateTurnDegreeDiffrence
|
||||
updateTurnVelocityDeadband = ((Scalar *)model)[0x27]; // @0x76c <- UpdateTurnVelocityDiffrence
|
||||
updatePositionDeadband = ((Scalar *)model)[0x26]; // @0x768 <- UpdatePositionDiffrence
|
||||
if (getenv("BT_REPL_LOG"))
|
||||
DEBUG_STREAM << "[deadband] pos=" << updatePositionDeadband
|
||||
<< " turnVel=" << updateTurnVelocityDeadband
|
||||
<< " turnAngle=" << updateTurnAngleDeadband << " (rad)" << std::endl;
|
||||
Wword(0x10c) = model->fieldA4;
|
||||
// NOTE: the decomp writes word slots this[0x15d]/this[0x15e]. Routed to the
|
||||
// scratch bank (unnamed pose-angle fields) -- writing through (float*)(this +
|
||||
|
||||
Reference in New Issue
Block a user