Skip to content

Commit

Permalink
Updated
Browse files Browse the repository at this point in the history
Updated for October 15th 2024 update.
  • Loading branch information
JonathanEke committed Oct 15, 2024
1 parent 091135f commit 8c968ff
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions DayZServerPatcher/src/main.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#include "pch.h"
#include "utils/utils.hpp"

std::string consoleTitle = "DayZ patched version";
std::string consoleTitle = "Patched version";
std::string filePath, fileBakPath;
std::vector<BYTE> fileBytes;

Expand Down Expand Up @@ -30,7 +30,9 @@ int main(int argc, char* argv[]) {

std::cout << "Created backup." << std::endl;

auto address = Utils::Scan(fileBytes.data(), fileBytes.size(), "40 53 56 57 41 54 41 57 48 81 EC ? ? ? ? 45 33 E4 48 8B D9 44");
//40 53 56 57 41 54 41 57 48 81 EC ? ? ? ? 45 33 E4 48 8B D9 44 (old)
//40 53 55 56 57 41 54 48 81 EC ? ? ? ? 45 33 E4 48 8B D9 44 89 (new)
auto address = Utils::Scan(fileBytes.data(), fileBytes.size(), "40 53 55 56 57 41 54 48 81 EC ? ? ? ? 45 33 E4 48 8B D9 44 89");
if (!address) {
std::cout << "Failed to find battleye init function." << std::endl;
system("pause");
Expand Down Expand Up @@ -58,7 +60,7 @@ int main(int argc, char* argv[]) {

std::cout << "Patched VAC check." << std::endl;

address = Utils::Scan(fileBytes.data(), fileBytes.size(), "44 61 79 5A 20 43 6F 6E");
address = Utils::Scan(fileBytes.data(), fileBytes.size(), "43 6F 6E 73 6F 6C 65 20 76");
if (address) {
memcpy((PVOID)address, consoleTitle.c_str(), consoleTitle.size());
std::cout << "Patched console title." << std::endl;
Expand Down

0 comments on commit 8c968ff

Please sign in to comment.