mirror of
https://github.com/spice2x/spice2x.github.io.git
synced 2026-08-02 23:00:42 -07:00
launcher: check for custom d3d9.dll in user's game directory (#309)
## Link to GitHub Issue, if one exists n/a ## Description of change Log a message if d3d9.dll (and friends) are found in the game root or the modules directory. This is to help with troubleshooting in cases where the user is unaware that d3d9 is being used to inject other DLLs (e.g., ifs_layeredfs), or when DX9 reimplementation is causing issues / crashes (e.g., dxvk). ## Testing Observed the new messages being logged in both modules / root directory.
This commit is contained in:
@@ -355,4 +355,16 @@ void libutils::check_duplicate_dlls() {
|
||||
(MODULE_PATH / filename).string());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void libutils::warn_if_dll_exists(const std::string &file_name) {
|
||||
if (fileutils::file_exists(MODULE_PATH / file_name)) {
|
||||
log_info("libutils", "found user-supplied {} in modules directory", file_name);
|
||||
return;
|
||||
}
|
||||
const auto &spice_bin_path = libutils::module_file_name(nullptr).parent_path();
|
||||
if (fileutils::file_exists(spice_bin_path / file_name)) {
|
||||
log_info("libutils", "found user-supplied {} next to spice executable path", file_name);
|
||||
return;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user