2.6.5: macOS and Linux fixes, fix refl/refr patches
This commit is contained in:
@@ -0,0 +1,2 @@
|
|||||||
|
[InternetShortcut]
|
||||||
|
URL=https://dotnet.microsoft.com/download/dotnet-framework/net48
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
[InternetShortcut]
|
||||||
|
URL=https://www.quicksfv.org/qsfv236x64.exe
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
[InternetShortcut]
|
||||||
|
URL=https://aka.ms/vs/16/release/vc_redist.x64.exe
|
||||||
Binary file not shown.
@@ -38,7 +38,7 @@ Cursor=1
|
|||||||
#Use 2 channels instead of 4 (when not using DivaSound)
|
#Use 2 channels instead of 4 (when not using DivaSound)
|
||||||
Stereo=1
|
Stereo=1
|
||||||
#Skip one or more menus -- 0=disabled, 1=guest, 2=guest+normal
|
#Skip one or more menus -- 0=disabled, 1=guest, 2=guest+normal
|
||||||
Quick_Start=1
|
Quick_Start=0
|
||||||
#Disable the scrolling sound effect
|
#Disable the scrolling sound effect
|
||||||
No_Scrolling_SFX=0
|
No_Scrolling_SFX=0
|
||||||
#Enhanced Stage Manager (sets a custom number of stages; "stage_manager" should be disabled in "components.ini")
|
#Enhanced Stage Manager (sets a custom number of stages; "stage_manager" should be disabled in "components.ini")
|
||||||
@@ -153,6 +153,7 @@ r.Width=1920
|
|||||||
r.Height=1080
|
r.Height=1080
|
||||||
|
|
||||||
[plugins]
|
[plugins]
|
||||||
|
DivaMovie.dva=0
|
||||||
DivaWig.dva=0
|
DivaWig.dva=0
|
||||||
DSCRemote.dva=0
|
DSCRemote.dva=0
|
||||||
custom_freeplay_text_example.p=0
|
custom_freeplay_text_example.p=0
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -215,6 +215,8 @@ void FindFiles(WIN32_FIND_DATAW* fd)
|
|||||||
do {
|
do {
|
||||||
if (!(fd->dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY))
|
if (!(fd->dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY))
|
||||||
{
|
{
|
||||||
|
if (fd->cFileName[0] == '.' && fd->cFileName[1] == '_') continue; // exclude macOS metadata
|
||||||
|
|
||||||
auto pos = wcslen(fd->cFileName);
|
auto pos = wcslen(fd->cFileName);
|
||||||
|
|
||||||
if (fd->cFileName[pos - 4] == '.' &&
|
if (fd->cFileName[pos - 4] == '.' &&
|
||||||
@@ -771,7 +773,7 @@ void Init()
|
|||||||
(PathFileExistsW(SHADERPATCH_TEMPLATE) && !PathFileExistsW(SHADERPATCH)) ||
|
(PathFileExistsW(SHADERPATCH_TEMPLATE) && !PathFileExistsW(SHADERPATCH)) ||
|
||||||
(PathFileExistsW(SHADERPATCHCONFIG_TEMPLATE) && !PathFileExistsW(SHADERPATCHCONFIG))
|
(PathFileExistsW(SHADERPATCHCONFIG_TEMPLATE) && !PathFileExistsW(SHADERPATCHCONFIG))
|
||||||
)
|
)
|
||||||
MessageBoxW(0, L"Could not install configuration files. Is the game in a read-only folder?", L"PD Loader", MB_ICONWARNING);
|
MessageBoxW(0, L"Could not install configuration files. Possible causes:\n\n- PD Loader was not installed correctly\n- The game is on a read-only drive\n- No privileges to write in the folder", L"PD Loader", MB_ICONWARNING);
|
||||||
|
|
||||||
CreateDirectoryW(L"plugins\\pv_equip", NULL);
|
CreateDirectoryW(L"plugins\\pv_equip", NULL);
|
||||||
const auto eq_modules = L"plugins\\pv_equip\\modules.ini";
|
const auto eq_modules = L"plugins\\pv_equip\\modules.ini";
|
||||||
|
|||||||
@@ -411,6 +411,8 @@ std::vector<PluginInfo> LoadPlugins()
|
|||||||
do {
|
do {
|
||||||
if (!(ffd.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY))
|
if (!(ffd.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY))
|
||||||
{
|
{
|
||||||
|
if (ffd.cFileName[0] == '.' && ffd.cFileName[1] == '_') continue; // exclude macOS metadata
|
||||||
|
|
||||||
auto pos = wcslen(ffd.cFileName);
|
auto pos = wcslen(ffd.cFileName);
|
||||||
|
|
||||||
if (ffd.cFileName[pos - 4] == '.' &&
|
if (ffd.cFileName[pos - 4] == '.' &&
|
||||||
@@ -487,11 +489,13 @@ std::vector<PluginInfo> LoadCustom()
|
|||||||
HANDLE hFind;
|
HANDLE hFind;
|
||||||
WIN32_FIND_DATAW ffd;
|
WIN32_FIND_DATAW ffd;
|
||||||
|
|
||||||
hFind = FindFirstFileW((PATCHES_DIR + L"\\*.p?").c_str(), &ffd);
|
hFind = FindFirstFileW((PATCHES_DIR + L"\\*.p*").c_str(), &ffd);
|
||||||
if (hFind != INVALID_HANDLE_VALUE) {
|
if (hFind != INVALID_HANDLE_VALUE) {
|
||||||
do {
|
do {
|
||||||
if (!(ffd.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY))
|
if (!(ffd.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY))
|
||||||
{
|
{
|
||||||
|
if (ffd.cFileName[0] == '.' && ffd.cFileName[1] == '_') continue; // exclude macOS metadata
|
||||||
|
|
||||||
auto pos = wcslen(ffd.cFileName);
|
auto pos = wcslen(ffd.cFileName);
|
||||||
|
|
||||||
if ((ffd.cFileName[pos - 2] == '.' && (ffd.cFileName[pos - 1] == 'p' || ffd.cFileName[pos - 1] == 'P')) ||
|
if ((ffd.cFileName[pos - 2] == '.' && (ffd.cFileName[pos - 1] == 'p' || ffd.cFileName[pos - 1] == 'P')) ||
|
||||||
|
|||||||
@@ -938,7 +938,7 @@ private: System::Windows::Forms::Button^ button_Wiki;
|
|||||||
this->MaximizeBox = false;
|
this->MaximizeBox = false;
|
||||||
this->Name = L"ui";
|
this->Name = L"ui";
|
||||||
this->StartPosition = System::Windows::Forms::FormStartPosition::CenterScreen;
|
this->StartPosition = System::Windows::Forms::FormStartPosition::CenterScreen;
|
||||||
this->Text = L"PD Launcher (2.6.4)";
|
this->Text = L"PD Launcher (2.6.5)";
|
||||||
this->TransparencyKey = System::Drawing::Color::Magenta;
|
this->TransparencyKey = System::Drawing::Color::Magenta;
|
||||||
this->FormClosing += gcnew System::Windows::Forms::FormClosingEventHandler(this, &ui::Ui_FormClosing);
|
this->FormClosing += gcnew System::Windows::Forms::FormClosingEventHandler(this, &ui::Ui_FormClosing);
|
||||||
this->FormClosed += gcnew System::Windows::Forms::FormClosedEventHandler(this, &ui::Ui_FormClosed);
|
this->FormClosed += gcnew System::Windows::Forms::FormClosedEventHandler(this, &ui::Ui_FormClosed);
|
||||||
|
|||||||
@@ -167,7 +167,7 @@ class PatchApplier710 : public PatchApplier {
|
|||||||
if (nPDLoaderText && !nHideFreeplay)
|
if (nPDLoaderText && !nHideFreeplay)
|
||||||
{
|
{
|
||||||
InjectCode((void*)0x00000001409F61F0, { 0x50, 0x44, 0x20, 0x4C, 0x6F, 0x61, 0x64, 0x65, 0x72,
|
InjectCode((void*)0x00000001409F61F0, { 0x50, 0x44, 0x20, 0x4C, 0x6F, 0x61, 0x64, 0x65, 0x72,
|
||||||
0x20, 0x32, 0x2E, 0x36, 0x2E, 0x34,
|
0x20, 0x32, 0x2E, 0x36, 0x2E, 0x35,
|
||||||
0x00});
|
0x00});
|
||||||
printf("[Patches] Show PD Loader text\n");
|
printf("[Patches] Show PD Loader text\n");
|
||||||
}
|
}
|
||||||
@@ -650,12 +650,14 @@ class PatchApplier710 : public PatchApplier {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// patch refract and reflect buffer sizes
|
// patch refract and reflect buffer sizes
|
||||||
if (nRefractResWidth != 512 && nRefractResHeight != 256)
|
if (nRefractResWidth != 512 || nRefractResHeight != 256)
|
||||||
{
|
{
|
||||||
InjectCode((void*)(0x140a24424), std::vector<uint8_t>((uint8_t*)&nRefractResWidth, (uint8_t*)((int64_t)&nRefractResWidth + 4)));
|
InjectCode((void*)(0x140a24424), std::vector<uint8_t>((uint8_t*)&nRefractResWidth, (uint8_t*)((int64_t)&nRefractResWidth + 4)));
|
||||||
InjectCode((void*)(0x140a24428), std::vector<uint8_t>((uint8_t*)&nRefractResHeight, (uint8_t*)((int64_t)&nRefractResHeight + 4)));
|
InjectCode((void*)(0x140a24428), std::vector<uint8_t>((uint8_t*)&nRefractResHeight, (uint8_t*)((int64_t)&nRefractResHeight + 4)));
|
||||||
|
|
||||||
|
printf("[Patches] Refraction resolution patched.\n");
|
||||||
}
|
}
|
||||||
if (nReflectResWidth != 512 && nReflectResHeight != 256)
|
if (nReflectResWidth != 512 || nReflectResHeight != 256)
|
||||||
{
|
{
|
||||||
InjectCode((void*)(0x140a2443c), std::vector<uint8_t>((uint8_t*)&nReflectResWidth, (uint8_t*)((int64_t)&nReflectResWidth + 4)));
|
InjectCode((void*)(0x140a2443c), std::vector<uint8_t>((uint8_t*)&nReflectResWidth, (uint8_t*)((int64_t)&nReflectResWidth + 4)));
|
||||||
InjectCode((void*)(0x140a24440), std::vector<uint8_t>((uint8_t*)&nReflectResHeight, (uint8_t*)((int64_t)&nReflectResHeight + 4)));
|
InjectCode((void*)(0x140a24440), std::vector<uint8_t>((uint8_t*)&nReflectResHeight, (uint8_t*)((int64_t)&nReflectResHeight + 4)));
|
||||||
@@ -697,6 +699,8 @@ class PatchApplier710 : public PatchApplier {
|
|||||||
InjectCode((void*)(0x14050294d), { 0x89, 0x01 }); // MOV dword ptr [RCX], EAX
|
InjectCode((void*)(0x14050294d), { 0x89, 0x01 }); // MOV dword ptr [RCX], EAX
|
||||||
InjectCode((void*)(0x14050294f), { 0xc3 }); // RET
|
InjectCode((void*)(0x14050294f), { 0xc3 }); // RET
|
||||||
}
|
}
|
||||||
|
|
||||||
|
printf("[Patches] Reflection resolution patched.\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
// lag compensation
|
// lag compensation
|
||||||
|
|||||||
@@ -80,6 +80,8 @@ void ApplyPatches() {
|
|||||||
try {
|
try {
|
||||||
for (std::filesystem::path p : std::filesystem::directory_iterator("../patches"))
|
for (std::filesystem::path p : std::filesystem::directory_iterator("../patches"))
|
||||||
{
|
{
|
||||||
|
if (std::filesystem::path(p).filename().string()._Starts_with("._")) continue; // exclude macOS metadata
|
||||||
|
|
||||||
std::string extension = std::filesystem::path(p).extension().string();
|
std::string extension = std::filesystem::path(p).extension().string();
|
||||||
if ((extension == ".p" || extension == ".P" || extension == ".p2" || extension == ".P2") &&
|
if ((extension == ".p" || extension == ".P" || extension == ".p2" || extension == ".P2") &&
|
||||||
GetPrivateProfileIntW(L"plugins", std::filesystem::path(p).filename().c_str(), TRUE, CONFIG_FILE))
|
GetPrivateProfileIntW(L"plugins", std::filesystem::path(p).filename().c_str(), TRUE, CONFIG_FILE))
|
||||||
@@ -87,6 +89,7 @@ void ApplyPatches() {
|
|||||||
std::cout << "[Patches] Reading custom patch file: " << std::filesystem::path(p).filename().string() << std::endl;
|
std::cout << "[Patches] Reading custom patch file: " << std::filesystem::path(p).filename().string() << std::endl;
|
||||||
ApplyCustomPatches(std::filesystem::path(p).wstring());
|
ApplyCustomPatches(std::filesystem::path(p).wstring());
|
||||||
}
|
}
|
||||||
|
else std::cout << "[Patches] Skipping disabled patch file: " << std::filesystem::path(p).filename().string() << std::endl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
catch (const std::filesystem::filesystem_error &e) {
|
catch (const std::filesystem::filesystem_error &e) {
|
||||||
|
|||||||
@@ -107,7 +107,7 @@ auto nMAG = GetPrivateProfileIntW(L"graphics", L"mag", 0, CONFIG_FILE);
|
|||||||
auto nGamma = GetPrivateProfileIntW(L"graphics", L"gamma", 100, CONFIG_FILE);
|
auto nGamma = GetPrivateProfileIntW(L"graphics", L"gamma", 100, CONFIG_FILE);
|
||||||
auto nStereo = GetPrivateProfileIntW(L"patches", L"stereo", TRUE, CONFIG_FILE);
|
auto nStereo = GetPrivateProfileIntW(L"patches", L"stereo", TRUE, CONFIG_FILE);
|
||||||
auto nCustomPatches = GetPrivateProfileIntW(L"patches", L"custom_patches", TRUE, CONFIG_FILE);
|
auto nCustomPatches = GetPrivateProfileIntW(L"patches", L"custom_patches", TRUE, CONFIG_FILE);
|
||||||
auto nQuickStart = GetPrivateProfileIntW(L"patches", L"quick_start", 1, CONFIG_FILE);
|
auto nQuickStart = GetPrivateProfileIntW(L"patches", L"quick_start", 0, CONFIG_FILE);
|
||||||
auto nNoScrollingSfx = GetPrivateProfileIntW(L"patches", L"no_scrolling_sfx", FALSE, CONFIG_FILE);
|
auto nNoScrollingSfx = GetPrivateProfileIntW(L"patches", L"no_scrolling_sfx", FALSE, CONFIG_FILE);
|
||||||
auto nEnablePvCustomization = GetPrivateProfileIntW(L"patches", L"enable_pv_customization", FALSE, CONFIG_FILE);
|
auto nEnablePvCustomization = GetPrivateProfileIntW(L"patches", L"enable_pv_customization", FALSE, CONFIG_FILE);
|
||||||
auto nNoHandScaling = GetPrivateProfileIntW(L"patches", L"no_hand_scaling", FALSE, CONFIG_FILE);
|
auto nNoHandScaling = GetPrivateProfileIntW(L"patches", L"no_hand_scaling", FALSE, CONFIG_FILE);
|
||||||
|
|||||||
Reference in New Issue
Block a user