Files
praxisandClaude Fable 5.2 60b6d4b7a5 Design records
59 files, from working commit b1a079a.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-19 01:32:48 +02:00

135 lines
8.7 KiB
Markdown

# Native owned items and equipment
The gateway-stopped native path now processes authenticated owned-item updates
through Forever's original object manager and inventory UI. This is partial
inventory support, not complete item gameplay.
`native/inventory_translation.cpp::translate` retains actual item/container
creates, owner and contained GUIDs, sparse values and the player's carried-slot
fields. Both halves of a legacy GUID are retained across partial updates. Unknown
or foreign items do not acquire identities through value packets. Destruction,
range removal, replacement and loss of ownership clear cached identities and
pending records. The cache is bounded to4096 owned objects. Initial type1 items
are already created by the existing SELF writer, so the adapter fills their
remaining values without issuing duplicate creates. Initial bags use real
container creates.
`src/forever_create.cpp::source_forever_serialize("--inventory-objects",...)`
uses pinned source `ItemData`, `ItemEnchantment`, `ContainerData`, `PlayerData`
and `ActivePlayerData` serializers. Input is self64/realm16/map32/count32,
then guid64/type8/kind8/field-count16 and index16/value32 pairs. No engine
function is called by this serializer. `ops/build_forever_create.py` extracts
the source methods and Classic mask remappers; only the audited visible-item
and active inventory branches of the player writers are enabled. The source
hash checks remain mandatory. Turtle field indices are generated from
`~/Servers/tortoise-wow/src/game/Objects/UpdateFields.h` by
`ops/turtle_entity_profile.py`; reference repositories are unchanged.
Owned values include stack count, duration, charges, durability, creator and
the seven actual Turtle enchant slots. This establishes their representation;
actual consumable/enchant use and all visual effects still require integration.
Random-property modifiers, full flags semantics, bank deltas and all item-data
collisions are not resolved here.
`NativeInventoryTranslation::gameplay` implements carried-root inventory swap
and auto-equip requests. The Forever reference
`Server/Packets/ItemPackets.cpp::{SwapInvItem,AutoEquipItem}::Read` and
`ItemPacketsCommon.cpp::operator>>(InvUpdate&)` define the count bit field,
advisory positions and request order. `Protocol/ClassicOpcodes.cpp::
TranslateClientOpcode70245` maps wire group41 to canonical40 for these requests.
Thus real70334 wire410007/410004 become Turtle10D/10A. Modern backpack35..50
maps to Turtle23..38; modern bag-equipment30..33 maps to19..22; gear0..18 remains
unchanged. Only genuinely cached owned items authorize a request. Nested bag
equip and bank requests are explicitly unsupported. Tortoise's
`Handlers/ItemHandler.cpp::{HandleSwapInvItemOpcode,HandleAutoEquipItemOpcode}`
remains authoritative for validity and resulting equipment.
Actual verification on2026-10-16, external gateway stopped:
- Forever461232 authenticated/world-entered with the adapter. One genuine GM
additem159 created server item36226 in backpack slot25. Water appeared and free
slots changed14→13. Removing exactly that one item restored free14; the server
row disappeared. No baseline item was removed. The initial coarse trace wait
timed out despite successful creation; no duplicate grant was attempted.
- Forever465107 used the original C pane and backpack to move existing sword
36198/entry25 from equipment15 to backpack25. Real wire410007 was7bytes;
server updates changed the pane and damage55..58→57..58. Right-click emitted
4100045bytes and restored the same sword to15 and damage55..58. Normal self
`.save` calls (`ChatHandler::HandleSaveCommand`) persisted the real state;
read-only SQL confirmed both positions. Pipe/policy errors remained0.
- `docs/evidence/gameplay/native-inventory/` contains reviewed before/after
screenshots, actual request/response metadata and authoritative item identity.
Equipment restoration is confirmed; no talent, health or permission change
was required. This does not verify every derived stat or equipment model.
- Full51-test regression passed31.41s. The added52nd metadata-retention test
passes separately. `ops/native_world_trace.py::WorldTrace` continuously collects
public opcode/length metadata during ordinary UI actions, de-duplicates ring
snapshots and explicitly reports lost rows or session resets. It reads no
authentication secrets or packet bodies.
Next dependencies: actual item-use/cast requests and results, auras/cooldowns,
temporary enchant application/expiry, full inventory errors, vendor transactions,
nearby vendors/trainers and talent reset. Turtle item12365 is Dense Stone material;
the usable Dense Sharpening Stone is12404, server spell16138. These identities
were read from the authoritative local `item_template`, not guessed.
Recovery: current sword slot15 and baseline inventory are restored. Private
baseline is in `recovery/item-gameplay-20261016-051313/`; credentials are absent.
No original executable, client data, server source or schema was modified. Close
the private client normally before rebuilding native modules. The prior native
merchant checkpoint is `ca5cbcd`; the existing gateway fallback is preserved.
## Subsequent shared item-use checkpoint
Actual70334 captured request and source-verified parser are recorded in
`evidence/gameplay/native-item-use-request.json`; `forever_item_use` rejects
unsupported optional location/movement/crafting semantics. `NativeInventoryTranslation::
use_item` requires the real cached cast item at the requested carried slot and
real known unit/owned-item target GUIDs. Turtle `HandleUseItemOpcode` independently
selects the actual item prototype spells; its unused spell_count is0. No unrelated
spell ID is substituted. The actual stationary food433 request is now forwarded.
Real client478021, external gateway stopped: ordinary `/use 0 1` generated the
request, Tortoise130 replied spell433/status0, and count4→3 was confirmed in the
native cache, live inventory API, visible bag and saved server row. One legitimate
self GM add117+1 restored4. See `evidence/gameplay/native-item-use/`. No HP or
progression change was needed. This verifies request/cast acceptance/count only;
healing, seated state, auras, animation, cooldowns and interruption remain unverified.
Bounded diagnostics retain exactly one authenticated-world3E0171 specimen≤256bytes
with its native result; other opcodes cannot enter that record. Public cast result
fields come from genuine server130 and112, without fabricating responses. A1312byte
owned-inventory snapshot exposes at most32 genuine item identities/stack/durability/
temporary-enchant rows and lifecycle counters, no account keys or credentials.
Ring metadata loss is reported explicitly. These diagnostics localized a stale
observation without changing the working field writer: restoration3→4 already
applies correctly in the actual engine. Ordinary `/use` works while some mouse
attempts emitted no request; actual169.6FPS, unlocked item and noncombat ruled out
low FPS/item-lock hypotheses. The exact mouse miss cause remains unconfirmed.
Full54/54 regression passed30.43s after the typed inventory/cast diagnostics and
actual food count verification. Original client and prefix remain preserved.
Stand-state request/acknowledgment is now native as well: source
`MiscPackets.cpp::StandStateChange::Read` consumes state8, while Tortoise
`MiscHandler.cpp::HandleStandStateChangeOpcode` reads state32 and accepts0/1/3/8
through ScheduleStandStateChange. Unit::SetStandState sends29D and removes
NOT_SEATED auras when standing. The pinned Classic remappers produce4701C9 for
Forever's state8+AnimKit32 update; no new engine function pointer is invoked.
Actual484931 verified poses, server acknowledgments and Food433 aura13→14→13
on standing; count restored4. See `evidence/gameplay/native-food-state/`.
The repeatable `ops/native_food_state_test.py` uses real input and server queries,
restores the one consumed food in finally, and leaves healing/native buff UI
explicitly unverified. Its bounded ChatFrame1 history query was verified in the
actual client and recovers source aura rows hidden above the visible viewport.
Real targeted stone12404/16138 applied enchant1643 to existing sword36198 through
original target cursor and /use16; consumed source item, authoritative save and
native damage+8 verified. Timer1EB needs its own reordered packed-GUID packet
470200; item-field duration alone produced0s. Fixed and verified native28m icon /
GetWeaponEnchantInfo1621002ms after direct reconnect. Source ItemHandler.cpp::
SendItemEnchantTimeUpdate, ItemPackets.cpp::ItemEnchantTimeUpdate::Write and
ClassicOpcodes remappers establish layout/opcode, Player.cpp sends seconds.
See evidence/gameplay/native-weapon-enchant. Cast bar absent (user corroborated);
START/GO lifecycle is the next shared dependency. Expiry/removal unverified.