HLE: implement IUnknown::QueryInterface and unit tests for xgame objects #901
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from Marvisak/VIctory. Originally posted by geiyiliyabumo on 2026-11-24T13:48:14Z.
Summary
Implements
IUnknown::QueryInterfaceacross all four staticxgameCOM objects (TITLE_OBJECT,FEATURES_OBJECT,INVITES_OBJECT,EVENTS_OBJECT, replacing all 4missing::<0>slots) and adds comprehensive synthetic unit tests incrates/victory-hle/src/modules/xgame.rs.Because external PR creation is currently restricted (
collaborators_only), the CI-green branch is ready on my fork for cherry-pick / review:geiyiliyabumo/VIctory@feat/xgame-missing-slotsgeiyiliyabumo/VIctory@299bc17(based onmainffe310e)Changes (
crates/victory-hle/src/modules/xgame.rs)query_interface: validatesoutandiid(E_POINTER, always zeroing*outbefore returning on error), answersIID_IUNKNOWNand each object's own IID withthis+S_OK, and returnsE_NOINTERFACEfor unknown IIDs or mismatched objects.query_interfaceat slot0inTITLE_VTABLE,FEATURES_VTABLE,INVITES_VTABLE, andEVENTS_VTABLE.QueryInterface(all 4 objects,IUnknown, own IID, wrong IID, nullout/iid) and existingxgamemethods.Verification (Windows 11 x64 MSVC)
rustfmt --edition 2024 --check crates/victory-hle/src/modules/xgame.rs: PASScargo xtask policy: PASS (154 files ok)cargo clippy -p victory-hle --all-targets --locked -- -D warnings(default +--features diagnostics): PASS (0 warnings)cargo test -p victory-hle --locked -- xgame: 15 passed, 0 failedAI-assisted; synthetic tests only, no game files.
Imported from Marvisak/VIctory. Originally posted by MichaelSmithAI on 2026-11-24T13:57:03Z.
Independent Win64/Wine check on
299bc17with one additional fixture. It obtained title, features, invites and events through the runtime’s QueryApiImpl entry point. Each returned a distinct IUnknown pointer. Querying each IUnknown for its own interface returned the original pointer, and the fixture released all three references acquired per object.All 16 tests selected by the
xgamefilter passed, including the new runtime lookup check. This verifies identity through the guest entry point. The objects use the existing static lifetime and fixed Release return value, so the test does not measure object destruction.Imported from Marvisak/VIctory. Originally posted by Marvisak on 2026-11-25T06:53:37Z.
Automated triage for the maintainers.
On
mainslot 0 (QueryInterface) of the four static objects incrates/victory-hle/src/modules/xgame.rsis stillmissing::<0>, so this fits the project. The change is already open as pull request #1174 by the same author (branchfeat/xgame-missing-slots), which is where review belongs. The decision is left to the maintainers there.Generated by Claude Code