feat(hle): skip the title's Bink movies on request (VICTORY_SKIP_BINK, off by default)
VICTORY_SKIP_BINK=1 skips the movies that play once (logos, the intro); =all skips the looping ones too. Unset, nothing changes: no import is rebound. The title's own Bink DLL still opens each movie; the exports a player loop calls on an open movie (BinkWait, BinkDoFrame*, BinkNextFrame, BinkGoto, BinkShouldSkip, BinkClose) are bound to wrappers that put a skipped movie on its last frame, so the title's own end-of-movie check ends it at once. Wiring for this tree (run.rs): SkipMovies wraps WithTitleDlls at startup, so the executable's and its DLLs' imports go through it, with the FidelityFX Interpose on top (it only looks at its own DLL and is unchanged); and it wraps the resolver LateDlls binds DLLs the title loads later with. Original author: C-GDev (fxceless/victory-fork pull request 613, 75fe122c; the idea is from XCL pull request #1053, the code was written anew for VIctory's loader). Ported by hand from CuteBooty/victory-8gb. Co-Authored-By: Claude Fable 5.2 <[email protected]>
This commit is contained in:
1 parent
c437b0594b
commit
e31f474068
3 files changed
+372
No files matched your search
@@ -219,6 +219,10 @@ pub fn run(
|
||||
inner: &resolver,
|
||||
dlls: &dlls,
|
||||
};
|
||||
// The title's Bink exports go through the movie skipper when
|
||||
// VICTORY_SKIP_BINK asks for it (bound as before otherwise); beneath
|
||||
// the FidelityFX interposer, which only looks at its own DLL.
|
||||
let with_dlls = victory_hle::modules::bink::SkipMovies { inner: &with_dlls };
|
||||
let show = |name: &str, report: BindReport| {
|
||||
println!(
|
||||
"bound {name}: {} hle, {} host, {} title, {} missing",
|
||||
@@ -495,6 +499,9 @@ impl LateDlls {
|
||||
inner: &old,
|
||||
dlls: &new,
|
||||
};
|
||||
// As at startup: Bink imports of DLLs loaded later too
|
||||
// (VICTORY_SKIP_BINK; bound as before otherwise).
|
||||
let resolver = victory_hle::modules::bink::SkipMovies { inner: &resolver };
|
||||
for (name, dll) in &new {
|
||||
println!(
|
||||
"title dll {name} at {:#x} (loaded by the title)",
|
||||
|
||||
Reference in new issue
Block a user