aorecomp

Anarchy Online classic in the browser

git clone https://aorecomp.ubeagle.com/code/aorecomp.git


docs/research-notes/team-loot-research/wire-audit.md (8710B)


Original 14.9.1 team loot wire audit

Read-only generated-source and PE audit, 2026-10-23. No runtime observation or shared REA session was performed. Addresses below are original PE VAs. Generated KKR addresses add 0x26000000; DDR addresses add 0x1b000000. Duplicate generated function copies were deduplicated by instruction address.

Identities and sources

Minimal contract (high confidence static observation)

Use existing CharacterAction key 5e477770 and the sender's normal character envelope. The key is already established by docs/teams.md; this audit directly confirms construction of the same CharacterActionIIR_t, not a new key hash derivation. Identities in this table are the two pairs AFTER the action integer.

Direction / purpose Action First pair Second pair
Client set /team loot all 127 (7f) {0,3} {0,0}
Client set /team loot leader 127 {0,4} {0,0}
Client set /team loot alpha 127 {0,5} {0,0}
Client query /team loot 145 (91) {0,0} {0,0}
Incoming native set feedback 127 {unused,mode} unused
Incoming native current-order feedback 145 unused {unused,mode}

The query RESULT uses the second pair, unlike the set result. Native consumers read only the pair's second word here. Zero the unused words/pairs for a minimal server producer. This zeroing is an implementation recommendation; the native consumer does not constrain all unused incoming words.

The mode integer is all=3, leader=4, alpha=5, not 0/1/2. KKR initializer 1003bf9a..1003c096, source kkr.dll/lifted-0019.c, builds the map at original 10306418: key 1 team (101bf07c), key 2 loot (101bf074), key 3 all (101bf070), key 4 leader (101bf068), key 5 alpha (101bf060).

1003e3c0 / export fStringToTeamCmd(const char*), source kkr.dll/lifted-0020.c, traverses that map and compares through MSVCRT _stricmp (IAT 1016f19c). Unknown text returns 0 at 1003e42d; valid text returns the node key at 1003e432. Because the same map contains team and loot, a hostile or ordinary invalid mode can produce 0, 1, or 2: server validation must whitelist 3/4/5. Native producer does not do that validation after converting the mode.

Command producer and local checks

IIR layout and native receiver

KKR 1007d4b0, source kkr.dll/lifted-0036.c, constructs a 0x34-byte CharacterActionIIR_t (literal type name 101b401c). Constructor arguments: owner identity, first pair, action integer, second pair. Object fields: +20 action, +24/+28 first pair, +2c/+30 second pair.

KKR 1008c740, source lifted-0041.c, receives four arguments from the handler at 100aff59 (lifted-0052.c): identity at source object +a8, integer at +9c, mode at +a0, and member/list pointer at +a4. It uses mode through the same fTeamCmdToString and special-cases mode3 at 1008c8cc to emit All team members can loot these remains.. (101c590c). Other modes may emit %s can loot these remains...(loot order: %s) (101c58dc). This corroborates the all=3 mapping. The containing IIR key/layout is not recovered in this audit; do not fabricate it from these offsets. This is an exact follow-up seed if corpse owner/status replication requires implementation.

Limits and unanswered server rules