diff --git a/.gitignore b/.gitignore
index 909fe7c..476e03a 100644
--- a/.gitignore
+++ b/.gitignore
@@ -38,3 +38,6 @@
# debug information files
*.dwo
+/.vs/UniversalSlashingSimulator/CopilotIndices
+/.vs
+/obj
diff --git a/Core/Memory/PatternScanner.cpp b/Core/Memory/PatternScanner.cpp
new file mode 100644
index 0000000..475efab
--- /dev/null
+++ b/Core/Memory/PatternScanner.cpp
@@ -0,0 +1,10 @@
+#include "PatternScanner.h"
+
+uintptr_t PatternScanner::FindGetEngineVersion()
+{
+ auto Results = Memcury::Scanner::FindPattern("40 53 48 83 EC ?? 48 8B D9 E8 ?? ?? ?? ?? 48 8B C8 41 B8"); // Chapter 1 - Chapter 2
+ if (!Results.IsValid())
+ return -1;
+
+ return Results.Get();
+}
diff --git a/Core/Memory/PatternScanner.h b/Core/Memory/PatternScanner.h
index 2369ccf..d1dafe8 100644
--- a/Core/Memory/PatternScanner.h
+++ b/Core/Memory/PatternScanner.h
@@ -1 +1,12 @@
-// TODO: @timmie replace with ur offset finder or whatever lol
\ No newline at end of file
+// TODO: @timmie replace with ur offset finder or whatever lol
+
+#include "../Common.h"
+#include "../../../external/memcury/memcury.h"
+
+class PatternScanner
+{
+public:
+ static PatternScanner* Get();
+public:
+ uintptr_t FindGetEngineVersion();
+};
\ No newline at end of file
diff --git a/Core/Versioning/VersionResolver.cpp b/Core/Versioning/VersionResolver.cpp
index 8ae72e6..493c7ea 100644
--- a/Core/Versioning/VersionResolver.cpp
+++ b/Core/Versioning/VersionResolver.cpp
@@ -382,13 +382,15 @@ namespace USS
// Pattern for GetEngineVersion (varies by version)
// @timmie
- uintptr_t CLAddr = TAOF::FindPattern(
- "48 8D 05 ?? ?? ?? ?? C3 CC CC CC CC CC CC CC CC 48 8D 05 ?? ?? ?? ?? C3"
- );
+ uintptr_t CLAddr = PatternScanner::Get()->FindGetEngineVersion();
- if (CLAddr)
+ if (CLAddr != -1)
{
- uintptr_t StringAddr = TAOF::ResolveRelativeAddress(CLAddr, 7, 3);
+ //uintptr_t StringAddr = TAOF::ResolveRelativeAddress(CLAddr, 7, 3);
+
+ // TODO: we need FString Implement class to do GetEngineVersion string
+ static FString(*GetEngineVersion)() = decltype(GetEngineVersion)(CLAddr);
+
if (StringAddr)
{
char VersionStr[64] = {};
diff --git a/UniversalSlashingSimulator.vcxproj b/UniversalSlashingSimulator.vcxproj
index 75861ea..6d470c5 100644
--- a/UniversalSlashingSimulator.vcxproj
+++ b/UniversalSlashingSimulator.vcxproj
@@ -74,7 +74,7 @@
Windows
true
- psapi.lib;dbghelp.lib;%(AdditionalDependencies)
+ psapi.lib;%(AdditionalDependencies)
$(ProjectDir)external\minhook\lib;%(AdditionalLibraryDirectories)
@@ -100,7 +100,7 @@
true
true
true
- psapi.lib;dbghelp.lib;%(AdditionalDependencies)
+ psapi.lib;%(AdditionalDependencies)
$(ProjectDir)external\minhook\lib;%(AdditionalLibraryDirectories)
UseLinkTimeCodeGeneration
@@ -110,8 +110,8 @@
+
-
@@ -142,7 +142,6 @@
-
diff --git a/UniversalSlashingSimulator.vcxproj.filters b/UniversalSlashingSimulator.vcxproj.filters
index f543162..9965dd4 100644
--- a/UniversalSlashingSimulator.vcxproj.filters
+++ b/UniversalSlashingSimulator.vcxproj.filters
@@ -56,9 +56,6 @@
{I7Q6P5R4-3N2M-8Q1L-P0O9-R8Q7P6O5N4M3}
-
- {0959a4cf-e16b-41c6-8c08-dcc99defca03}
-
@@ -123,8 +120,8 @@
Entry
-
- Core\Diagnostics
+
+ Core\Memory
@@ -207,8 +204,5 @@
STW\Building
-
- Core\Diagnostics
-
\ No newline at end of file
diff --git a/UniversalSlashingSimulator.vcxproj.user b/UniversalSlashingSimulator.vcxproj.user
index 88a5509..966b4ff 100644
--- a/UniversalSlashingSimulator.vcxproj.user
+++ b/UniversalSlashingSimulator.vcxproj.user
@@ -1,4 +1,6 @@
-
+
+ true
+
\ No newline at end of file