Skip to content

Commit

Permalink
Waiting for red4ext now
Browse files Browse the repository at this point in the history
  • Loading branch information
maximegmd committed Sep 21, 2023
1 parent 1bb70eb commit 465e46f
Show file tree
Hide file tree
Showing 11 changed files with 78 additions and 54 deletions.
16 changes: 8 additions & 8 deletions ida/patterns.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ def get_groups() -> List[Group]:
Item(name='InstanceOffset', pattern='48 8B C4 48 89 58 08 48 89 68 10 48 89 70 18 4C 89 48 20 57 41 56 41 57 48 83 EC 30 8B 01 45 8B', expected=1, offset=62), # ok
Item(name='_DoNotUse_RenderQueueOffset', pattern='39 72 24 74 5B 48 8B 4A 18 4C 8D 8C 24 88 00 00 00 8B 42 24 44 8B C7 48 8B 95 ? ? ? ?', expected=1) # ok
], functions=[
Item(name='Resize', pattern='44 88 4C 24 20 44 89 44 24 18 89 54 24 10 89 4C', expected=1),
Item(name='Shutdown', pattern='48 89 6C 24 20 41 56 48 83 EC 20 48 8D 05', expected=1)
Item(name='Resize', pattern='48 8B C4 44 88 48 20 44 89 40 18 89 50 10 89 48 08 55 53 56 57 41 54 41 55 41 56 41 57 48 8D 68 88 48 81 EC 38 01 00 00', expected=1),
Item(name='Shutdown', pattern='40 53 48 83 EC 20 48 8B D9 48 8D 05 ? ? ? ? 48 81 C1 98 00 00 00 48 89 01 E8', expected=1)
]),
Group(name='CRenderNode_Present', functions=[
Item(name='DoInternal', pattern='48 8B C4 48 89 58 08 48 89 68 10 48 89 70 18 4C 89 48 20 57 41 56 41 57 48 83 EC 30 8B 01 45 8B', expected=1) # ok
Expand Down Expand Up @@ -67,18 +67,18 @@ def get_groups() -> List[Group]:
Item(name='SetRecordID', pattern='48 89 5C 24 10 48 89 4C 24 08 55 48 8B EC 48 83 EC 40 48 8B DA 48 8D 4D E0 48 8D 55 10 E8', expected=1) # ok
]),
Group(name='CPatches', functions=[
Item(name='BoundaryTeleport', pattern='48 8B C4 55 53 41 54 48 8D A8 ? ? ? ? 48 81 EC ? ? ? ? 48 89 70 10 48 8D 59 48', expected=1),
#Item(name='BoundaryTeleport', pattern='48 8B C4 55 53 41 54 48 8D A8 ? ? ? ? 48 81 EC ? ? ? ? 48 89 70 10 48 8D 59 48', expected=1),
Item(name='IntroMovie', pattern='48 89 5C 24 08 57 48 83 EC 20 48 8B 44 24 50 48 8B D9 48 89 41 08', expected=1), # ok
Item(name='Vignette', pattern='48 8B 41 30 48 83 78 68 00 74', expected=1),
Item(name='MinimapFlicker', pattern='83 79 2C 00 48 8B F2 4C', expected=1),
Item(name='OptionsInit', pattern='40 53 48 83 EC 40 48 8B D9 48 8D 4C 24 20 E8 ? ? ? ? E8 ? ? ? ? 4C 8B 43 08', expected=1),
Item(name='SkipStartScreen', pattern='74 5F E8 ? ? ? ? 48 8D 4C 24 20 8B D8 E8 ? ? ? ? 48 8B C8 8B D3 E8', expected=2, index=1),
#Item(name='Vignette', pattern='48 8B 41 30 48 83 78 68 00 74', expected=1),
#Item(name='MinimapFlicker', pattern='83 79 2C 00 48 8B F2 4C', expected=1),
#Item(name='OptionsInit', pattern='40 53 48 83 EC 40 48 8B D9 48 8D 4C 24 20 E8 ? ? ? ? E8 ? ? ? ? 4C 8B 43 08', expected=1),
#Item(name='SkipStartScreen', pattern='74 5F E8 ? ? ? ? 48 8D 4C 24 20 8B D8 E8 ? ? ? ? 48 8B C8 8B D3 E8', expected=2, index=1),
]),
Group(name='CGame', functions=[
Item(name='Main', pattern='48 89 5C 24 10 55 56 57 48 8B EC 48 81 EC 80 00 00 00 48 8B F9 0F 29 74 24 70 0F 29 7C 24 60 48 8D 4D C0', expected=1) # ok
]),
Group(name='CBaseInitializationState', functions=[
Item(name='OnTick', pattern='48 83 EC 28 48 8B 05 ? ? ? ? 4C 8B C2 48 85 C0 75 12 8D 50 03 49 8B C8 E8 ? ? ? ?', expected=1) # ok
Item(name='OnTick', pattern='40 53 48 83 EC 20 48 8B 05 ? ? ? ? 33 DB 4C 8B C2 48 85 C0 ? ? ? ?', expected=1) # ok
]),
Group(name='CInitializationState', functions=[
Item(name='OnTick', pattern='40 53 48 83 EC 30 48 8B 05 ? ? ? ? 33 DB 4C 8B C2 8B 88 08 01 00 00', expected=1) # ok
Expand Down
1 change: 1 addition & 0 deletions src/Image.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ void Image::Initialize()
{{0x1C, 0xF0, 0xFC, 0x79, 0x23, 0x64, 0x67, 0x49, 0xBC, 0x54, 0xBA, 0x1E, 0xAC, 0xBC, 0xEB, 0xDA}, MakeVersion(1, 6202)},
{{0x50, 0xd2, 0x43, 0xd9, 0x99, 0x74, 0x1d, 0x46, 0xaf, 0x27, 0xdc, 0x1f, 0x4d, 0x81, 0x43, 0x9f}, MakeVersion(1, 63)},
{{0x26, 0xd4, 0xd1, 0xf8, 0x2a, 0x64, 0x77, 0x4e, 0xa2, 0xde, 0x12, 0x85, 0xce, 0x8a, 0x08, 0x05}, MakeVersion(1, 6301)},
{{0xd3, 0x6a, 0x87, 0x91, 0x64, 0xb1, 0x07, 0x44, 0xb5, 0x82, 0xbd, 0x9f, 0x38, 0x1e, 0x93, 0x1f}, MakeVersion(2, 0)},
};

mem::module mainModule = mem::module::main();
Expand Down
2 changes: 1 addition & 1 deletion src/Image.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ struct Image
{
void Initialize();

static std::tuple<uint32_t, uint16_t> GetSupportedVersion() noexcept { return std::make_tuple(1, 6301); }
static std::tuple<uint32_t, uint16_t> GetSupportedVersion() noexcept { return std::make_tuple(2, 0); }

static uint64_t MakeVersion(const uint32_t acMajor, const uint16_t acMinor) noexcept { return static_cast<uint64_t>(acMajor) << 32 | static_cast<uint64_t>(acMinor) << 16; }

Expand Down
7 changes: 5 additions & 2 deletions src/dllmain.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ static void Initialize()
{
try
{
while (!IsDebuggerPresent())
Sleep(1000);

MH_Initialize();

CET::Initialize();
Expand All @@ -34,7 +37,7 @@ static void Initialize()

// initialize patches

if (options.Patches.SkipStartMenu)
/*if (options.Patches.SkipStartMenu)
StartScreenPatch();
if (options.Patches.DisableIntroMovies)
Expand All @@ -49,7 +52,7 @@ static void Initialize()
if (options.Patches.MinimapFlicker)
MinimapFlickerPatch();
OptionsInitHook();
OptionsInitHook();*/

MH_EnableHook(nullptr);
}
Expand Down
2 changes: 2 additions & 0 deletions src/patches/DisableBoundaries.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#include <stdafx.h>

/*
void DisableBoundaryTeleportPatch()
{
// Disarm the WorldBoundarySystem/Tick function
Expand All @@ -21,3 +22,4 @@ void DisableBoundaryTeleportPatch()
Log::Info("Disable boundary teleport: success");
}
*/
2 changes: 2 additions & 0 deletions src/patches/DisableVignette.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#include <stdafx.h>

/*
void DisableVignettePatch()
{
const RED4ext::RelocPtr<uint8_t> func(CyberEngineTweaks::Addresses::CPatches_Vignette);
Expand All @@ -20,3 +21,4 @@ void DisableVignettePatch()
Log::Info("Disable vignette patch: success");
}
*/
2 changes: 2 additions & 0 deletions src/patches/MinimapFlicker.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#include <stdafx.h>

/*
void MinimapFlickerPatch()
{
const RED4ext::RelocPtr<uint8_t> func(CyberEngineTweaks::Addresses::CPatches_MinimapFlicker);
Expand All @@ -20,3 +21,4 @@ void MinimapFlickerPatch()
Log::Info("Minimap Flicker Patch: success");
}
*/
2 changes: 2 additions & 0 deletions src/patches/OptionsPatch.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ void* HookGameOptionInit(GameOption* apThis)
return RealGameOptionInit(apThis);
}

/*
void OptionsInitHook()
{
const RED4ext::RelocPtr<uint8_t> func(CyberEngineTweaks::Addresses::CPatches_OptionsInit);
Expand All @@ -52,3 +53,4 @@ void OptionsInitHook()
else
Log::Warn("Hidden options hook: failed");
}
*/
2 changes: 2 additions & 0 deletions src/patches/SkipStartScreen.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#include <stdafx.h>

/*
void StartScreenPatch()
{
const RED4ext::RelocPtr<uint8_t> func(CyberEngineTweaks::Addresses::CPatches_SkipStartScreen);
Expand All @@ -24,3 +25,4 @@ void StartScreenPatch()
Log::Info("Start screen patch: success");
}
*/
90 changes: 50 additions & 40 deletions src/reverse/Addresses.h
Original file line number Diff line number Diff line change
Expand Up @@ -8,85 +8,95 @@
*/
#include <cstdint>

// Addresses for Cyberpunk 2077, version 1.63.
namespace CyberEngineTweaks::Addresses
{
constexpr uintptr_t ImageBase = 0x140000000;

#pragma region CBaseInitializationState
constexpr uintptr_t CBaseInitializationState_OnTick = 0x140A83490 - ImageBase; // 48 83 EC 28 48 8B 05 ? ? ? ? 4C 8B C2 48 85 C0 75 12 8D 50 03 49 8B C8 E8 ? ? ? ?, expected: 1, index: 0
constexpr uintptr_t CBaseInitializationState_OnTick = 0x14084A6EC - ImageBase; // 40 53 48 83 EC 20 48 8B 05 ? ? ? ? 33 DB 4C 8B C2 48 85 C0 ? ? ? ?, expected: 1, index: 0
#pragma endregion

#pragma region CGameApplication
constexpr uintptr_t CGameApplication_Run = 0x140A81B30 - ImageBase; // 48 89 5C 24 08 57 48 83 EC 20 48 8B D9 33 FF 90 E8 ? ? ? ? 84 C0, expected: 1, index: 0
#pragma region CGame
constexpr uintptr_t CGame_Main =
0x1402C5960 - ImageBase; // 48 89 5C 24 10 55 56 57 48 8B EC 48 81 EC 80 00 00 00 48 8B F9 0F 29 74 24 70 0F 29 7C 24 60 48 8D 4D C0, expected: 1, index: 0
#pragma endregion

#pragma region CInitializationState
constexpr uintptr_t CInitializationState_OnTick = 0x140A83790 - ImageBase; // 48 83 EC 28 48 8B 05 ? ? ? ? 4C 8B C2 8B 88 F8 00 00 00 85 C9 74 3D 83 E9 02 74 25 83 E9 01, expected: 1, index: 0
constexpr uintptr_t CInitializationState_OnTick = 0x14084A7A8 - ImageBase; // 40 53 48 83 EC 30 48 8B 05 ? ? ? ? 33 DB 4C 8B C2 8B 88 08 01 00 00, expected: 1, index: 0
#pragma endregion

#pragma region CPatches
constexpr uintptr_t CPatches_BoundaryTeleport = 0x141B41550 - ImageBase; // 48 8B C4 55 53 41 54 48 8D A8 ? ? ? ? 48 81 EC ? ? ? ? 48 89 70 10 48 8D 59 48, expected: 1, index: 0
constexpr uintptr_t CPatches_IntroMovie = 0x140209220 - ImageBase; // 48 89 5C 24 08 57 48 83 EC 20 48 8B 44 24 50 48 8B D9 48 89 41 08, expected: 1, index: 0
constexpr uintptr_t CPatches_Vignette = 0x14118FB50 - ImageBase; // 48 8B 41 30 48 83 78 68 00 74, expected: 1, index: 0
constexpr uintptr_t CPatches_MinimapFlicker = 0x1425C233D - ImageBase; // 83 79 2C 00 48 8B F2 4C, expected: 1, index: 0
constexpr uintptr_t CPatches_OptionsInit = 0x142C315E0 - ImageBase; // 40 53 48 83 EC 40 48 8B D9 48 8D 4C 24 20 E8 ? ? ? ? E8 ? ? ? ? 4C 8B 43 08, expected: 1, index: 0
constexpr uintptr_t CPatches_SkipStartScreen = 0x142A668F0 - ImageBase; // 74 5F E8 ? ? ? ? 48 8D 4C 24 20 8B D8 E8 ? ? ? ? 48 8B C8 8B D3 E8, expected: 2, index: 1
constexpr uintptr_t CPatches_AmdSMT = 0x142BDA26B - ImageBase; // 75 2D 33 C9 B8 01 00 00 00 0F A2 8B C8 C1 F9 08, expected: 1, index: 0
constexpr uintptr_t CPatches_IntroMovie = 0x14011D85C - ImageBase; // 48 89 5C 24 08 57 48 83 EC 20 48 8B 44 24 50 48 8B D9 48 89 41 08, expected: 1, index: 0
#pragma endregion

#pragma region CPhotoMode
constexpr uintptr_t CPhotoMode_SetRecordID = 0x142E057C0 - ImageBase; // 48 8B C4 55 57 48 8D 68 A1 48 81 EC 98 00 00 00 48 89 58 08 48 8B D9 48 89 70 18 48 8D 4D 27 48, expected: 1, index: 0
constexpr uintptr_t CPhotoMode_SetRecordID =
0x140817CE4 - ImageBase; // 48 89 5C 24 10 48 89 4C 24 08 55 48 8B EC 48 83 EC 40 48 8B DA 48 8D 4D E0 48 8D 55 10 E8, expected: 1, index: 0
#pragma endregion

#pragma region CRenderGlobal
constexpr uintptr_t CRenderGlobal_InstanceOffset = 0x144E167E0 - ImageBase; // 48 89 5C 24 08 48 89 6C 24 18 48 89 74 24 20 57 41 56 41 57 48 83 EC 30 8B 01 4C 8B F9 48, expected: 1, index: 0, offset: 41
constexpr uintptr_t CRenderGlobal__DoNotUse_RenderQueueOffset = 0x151FA43A9 - ImageBase; // 49 39 29 0F 84 ? ? ? ? 41 39 69 24 0F 84 ? ? ? ? 49 8B 95, expected: 1, index: 0, offset: 0
constexpr uintptr_t CRenderGlobal_Resize = 0x142D18CC0 - ImageBase; // 44 88 4C 24 20 44 89 44 24 18 89 54 24 10 89 4C, expected: 1, index: 0
constexpr uintptr_t CRenderGlobal_Shutdown = 0x142D02750 - ImageBase; // 48 89 6C 24 20 41 56 48 83 EC 20 48 8D 05, expected: 1, index: 0
constexpr uintptr_t CRenderGlobal_InstanceOffset =
0x1432EDA60 - ImageBase; // 48 8B C4 48 89 58 08 48 89 68 10 48 89 70 18 4C 89 48 20 57 41 56 41 57 48 83 EC 30 8B 01 45 8B, expected: 1, index: 0, offset: 62
constexpr uintptr_t CRenderGlobal__DoNotUse_RenderQueueOffset =
0x1B5EF8520 - ImageBase; // 39 72 24 74 5B 48 8B 4A 18 4C 8D 8C 24 88 00 00 00 8B 42 24 44 8B C7 48 8B 95 ? ? ? ?, expected: 1, index: 0, offset: 0
constexpr uintptr_t CRenderGlobal_Resize =
0x140908F78 - ImageBase; // 48 8B C4 44 88 48 20 44 89 40 18 89 50 10 89 48 08 55 53 56 57 41 54 41 55 41 56 41 57 48 8D 68 88 48 81 EC 38 01 00 00, expected: 1, index: 0
constexpr uintptr_t CRenderGlobal_Shutdown = 0x141041734 - ImageBase; // 40 53 48 83 EC 20 48 8B D9 48 8D 05 ? ? ? ? 48 81 C1 98 00 00 00 48 89 01 E8, expected: 1, index: 0
#pragma endregion

#pragma region CRenderNode_Present
constexpr uintptr_t CRenderNode_Present_DoInternal = 0x142D1B280 - ImageBase; // 48 89 5C 24 08 48 89 6C 24 18 48 89 74 24 20 57 41 56 41 57 48 83 EC 30 8B 01 4C 8B F9 48, expected: 1, index: 0
constexpr uintptr_t CRenderNode_Present_DoInternal =
0x140655CE0 - ImageBase; // 48 8B C4 48 89 58 08 48 89 68 10 48 89 70 18 4C 89 48 20 57 41 56 41 57 48 83 EC 30 8B 01 45 8B, expected: 1, index: 0
#pragma endregion

#pragma region CRunningState
constexpr uintptr_t CRunningState_OnTick = 0x140A838D0 - ImageBase; // 40 53 48 83 EC 20 48 8B 0D ? ? ? ? 48 8B DA E8 ? ? ? ? 84 C0, expected: 1, index: 0
constexpr uintptr_t CRunningState_OnTick = 0x14084A744 - ImageBase; // 40 53 48 83 EC 30 83 64 24 28 00 48 8D 05 ? ? ? ? 48 8B 0D ? ? ? ? 48 8B DA, expected: 1, index: 0
#pragma endregion

#pragma region CScript
constexpr uintptr_t CScript_RunPureScript = 0x140215B60 - ImageBase; // 40 55 48 81 EC D0 00 00 00 48 8D 6C 24 40 8B, expected: 1, index: 0
constexpr uintptr_t CScript_AllocateFunction = 0x1401B6290 - ImageBase; // BA B8 00 00 00 48 8D 4D D7 E8, expected: 3, index: 0
constexpr uintptr_t CScript_Log = 0x1401F7DE0 - ImageBase; // 40 53 48 83 EC ? 48 8D 4C 24 20 48 8B DA E8 ? ? ? ? 33 D2 48 8D 4C 24 40 E8, expected: 1, index: 0
constexpr uintptr_t CScript_LogError = 0x1401F7DE0 - ImageBase; // 40 53 48 83 EC ? 48 8D 4C 24 20 48 8B DA E8 ? ? ? ? 33 D2 48 8D 4C 24 40 E8, expected: 1, index: 0
constexpr uintptr_t CScript_LogWarning = 0x1401F7DE0 - ImageBase; // 40 53 48 83 EC ? 48 8D 4C 24 20 48 8B DA E8 ? ? ? ? 33 D2 48 8D 4C 24 40 E8, expected: 1, index: 0
constexpr uintptr_t CScript_ToStringDEBUG = 0x140BE8820 - ImageBase; // 48 89 5C 24 08 57 48 83 EC 20 FE 42 62 4C 8D 15 ? ? ? ? 33 C9 33 C0, expected: 4, index: 2
constexpr uintptr_t CScript_LogChannel = 0x1401F7E80 - ImageBase; // 4C 8B DC 49 89 5B 08 49 89 73 18 57 48 83 EC 70 48 8B 02 ? ? ? ? ? ? ? FE 42 62 4D 8D 43 10 33 FF 45 33 C9 49 89 7B 10 48 8B DA 48 89 7A, expected: 1, index: 0
constexpr uintptr_t CScript_LogChannelWarning = 0x1401F7E80 - ImageBase; // 4C 8B DC 49 89 5B 08 49 89 73 18 57 48 83 EC 70 48 8B 02 ? ? ? ? ? ? ? FE 42 62 4D 8D 43 10 33 FF 45 33 C9 49 89 7B 10 48 8B DA 48 89 7A, expected: 1, index: 0
constexpr uintptr_t CScript_TDBIDConstructorDerive = 0x142C2A650 - ImageBase; // 40 53 48 83 EC 30 33 C0 4C 89 44 24 20 48 8B DA, expected: 1, index: 0
constexpr uintptr_t CScript_TranslateBytecode = 0x1402851A0 - ImageBase; // 4C 8B DC 55 53 57 41 55 49 8D 6B A1 48 81 EC 98 00 00 00 48 8B 1A 4C 8B E9 8B 42 0C 48 8D 3C C3, expected: 1, index: 0
constexpr uintptr_t CScript_TweakDBLoad = 0x140BE6B50 - ImageBase; // 48 89 5C 24 18 55 57 41 56 48 8B EC 48 83 EC 70 48 8B D9 45 33 F6 48 8D, expected: 1, index: 0
constexpr uintptr_t CScript_RegisterMemberFunction = 0x140214E50 - ImageBase; // 48 89 5C 24 08 57 48 83 EC 20 49 8B C1 4D 8B D0 44 8B 4C 24 58 48 8B DA 41 83 C9 03, expected: 1, index: 0
constexpr uintptr_t CScript_RunPureScript = 0x14027EB94 - ImageBase; // 40 55 48 81 EC D0 00 00 00 48 8D 6C 24 40 8B, expected: 1, index: 0
constexpr uintptr_t CScript_AllocateFunction = 0x141F91E6C - ImageBase; // 40 53 48 83 EC 30 BA B8 00 00 00 48 8D 4C 24 20 E8, expected: 2, index: 0
constexpr uintptr_t CScript_Log = 0x140EC5D7C - ImageBase; // 48 8B C4 53 48 83 EC 70 48 83 60 C0 00 48 8D 48 C8 83 60 BC 00, expected: 3, index: 0
constexpr uintptr_t CScript_LogError = 0x14109ECF8 - ImageBase; // 48 8B C4 53 48 83 EC 70 48 83 60 C0 00 48 8D 48 C8 83 60 BC 00, expected: 3, index: 1
constexpr uintptr_t CScript_LogWarning = 0x141136F70 - ImageBase; // 48 8B C4 53 48 83 EC 70 48 83 60 C0 00 48 8D 48 C8 83 60 BC 00, expected: 3, index: 2
constexpr uintptr_t CScript_ToStringDEBUG = 0x1421CD844 - ImageBase; // 48 89 5C 24 08 57 48 83 EC 20 83 64 24 38 00 4C 8D 15 ? ? ? ? FE 42 62 33 C0, expected: 4, index: 2
constexpr uintptr_t CScript_LogChannel = 0x140D01450 - ImageBase; // 48 89 5C 24 08 48 89 74 24 18 55 48 8B EC 48 83 EC 70 48 8B 02 48 8D 35 ? ? ? ? 48 83 65 18 00 4C 8D 45 18 48
// 83 62 30 00 45 33 C9 48 83 62 38 00, expected: 2, index: 0
constexpr uintptr_t CScript_LogChannelWarning = 0x141F9E2F8 - ImageBase; // 48 89 5C 24 08 48 89 74 24 18 55 48 8B EC 48 83 EC 70 48 8B 02 48 8D 35 ? ? ? ? 48 83 65 18 00 4C 8D 45
// 18 48 83 62 30 00 45 33 C9 48 83 62 38 00, expected: 2, index: 1
constexpr uintptr_t CScript_TDBIDConstructorDerive = 0x1405981F8 - ImageBase; // 48 89 5C 24 10 48 89 6C 24 18 48 89 74 24 20 57 45 33 C9 48 8B FA, expected: 1, index: 0
constexpr uintptr_t CScript_TranslateBytecode =
0x140601D84 - ImageBase; // 40 53 55 56 57 41 54 41 56 41 57 48 83 EC 60 48 8B 1A 48 8B E9 8B 42 0C 4C 8D 24 C3, expected: 1, index: 0
constexpr uintptr_t CScript_TweakDBLoad =
0x141410CBC - ImageBase; // 48 89 5C 24 10 48 89 7C 24 18 55 48 8B EC 48 83 EC 70 48 8B F9 48 8B DA 48 8B 0D ? ? ? ? 48 8B 01 FF 90 B8 00 00 00, expected: 1, index: 0
constexpr uintptr_t CScript_RegisterMemberFunction =
0x140ADCB6C - ImageBase; // 40 53 48 83 EC 20 49 8B C1 4D 8B D0 44 8B 4C 24 58 4C 8B DA 41 83 C9 03 4C 8B C0 49 8B D2 48 8B D9 E8, expected: 1, index: 0
#pragma endregion

#pragma region CShutdownState
constexpr uintptr_t CShutdownState_OnTick = 0x140A839E0 - ImageBase; // 48 89 6C 24 18 56 48 83 EC 30 48 8B 0D ? ? ? ?, expected: 1, index: 0
constexpr uintptr_t CShutdownState_OnTick = 0x140380910 - ImageBase; // 40 53 48 83 EC 20 48 8B DA E8 ? ? ? ? 48 8B CB 89 83 B0 02 00 00 , expected: 1, index: 0
#pragma endregion

#pragma region CWinapi
constexpr uintptr_t CWinapi_ClipToCenter = 0x14079B530 - ImageBase; // 48 89 5C 24 08 57 48 83 EC 30 48 8B 99 ? 01 00 00 48 8B F9 FF, expected: 1, index: 0
constexpr uintptr_t CWinapi_ClipToCenter = 0x140297FA8 - ImageBase; // 48 89 5C 24 08 55 48 8B EC 48 83 EC 30 48 8B D9 48 8B 89 68 01 00 00, expected: 1, index: 0
#pragma endregion

#pragma region gameIGameSystem
constexpr uintptr_t gameIGameSystem_Constructor = 0x140B08F76 - ImageBase; // 48 8B D9 E8 ? ? ? ? 48 8D 05 ? ? ? ? 48 C7 43 40 00 00 00 00, expected: 2, index: 0
constexpr uintptr_t gameIGameSystem_Initialize = 0x142E071E0 - ImageBase; // 48 89 5C 24 18 48 89 6C 24 20 57 48 83 EC 30 48 8B 42 78, expected: 1, index: 0
constexpr uintptr_t gameIGameSystem_UnInitialize = 0x142E05E50 - ImageBase; // 40 53 48 83 EC 20 48 8B D9 E8 ? ? ? ? 33 C0 48 89 43 50 48 89 43 48, expected: 1, index: 0
constexpr uintptr_t gameIGameSystem_Spawn = 0x142E083E0 - ImageBase; // 48 89 5C 24 18 55 56 41 54 41 56 41 57 48 8D 6C 24 90 48 81 EC 70 01 00 00 48 83 79 50 00 49 8B, expected: 1, index: 0
constexpr uintptr_t gameIGameSystem_Despawn = 0x142E05E80 - ImageBase; // 48 89 5C 24 10 48 89 6C 24 18 56 57 41 54 41 56 41 57 48 83 EC 50 4C 8B F9 0F 57 C0 48 83 C1 41, expected: 1, index: 0
constexpr uintptr_t gameIGameSystem_SpawnCallback = 0x141105540 - ImageBase; // 48 89 5C 24 18 48 89 6C 24 20 56 57 41 56 48 83 EC 70 48 8B F1 48 8B EA 48 83 C1 48 E8, expected: 1, index: 0
constexpr uintptr_t gameIGameSystem_Constructor =
0x1407BBEE0 - ImageBase; // 48 83 EC 28 E8 ? ? ? ? 4C 8D 0D ? ? ? ? 48 8B C1 4C 89 09 48 83 61 48 00 48 83 61 50 00 48 83 C4 28 C3, expected: 3, index: 0
constexpr uintptr_t gameIGameSystem_Initialize = 0x1407147C0 - ImageBase; // 48 89 5C 24 08 57 48 83 EC 30 48 8B 42 78 4C 8B CA 48 8B D9, expected: 1, index: 0
constexpr uintptr_t gameIGameSystem_UnInitialize = 0x141F96058 - ImageBase; // 48 89 5C 24 10 48 89 74 24 18 57 48 83 EC 20 48 8B F9 48 8D 51 42, expected: 2, index: 1
constexpr uintptr_t gameIGameSystem_Spawn =
0x140668FEC - ImageBase; // 48 89 5C 24 10 48 89 74 24 18 55 57 41 56 48 8D 6C 24 B0 48 81 EC 50 01 00 00 48 83 79 50 00 49 8B D9 4D 8B F0, expected: 1, index: 0
constexpr uintptr_t gameIGameSystem_Despawn =
0x140578DB4 -
ImageBase; // 48 8B C4 48 89 58 08 48 89 68 10 48 89 70 18 48 89 78 20 41 56 48 83 EC 40 48 8B E9 0F 57 C0 48 83 C1 41 48 8B F2 F3 0F 7F 40 D8 E8, expected: 1, index: 0
constexpr uintptr_t gameIGameSystem_SpawnCallback =
0x140496DB4 - ImageBase; // 48 89 5C 24 10 48 89 6C 24 18 48 89 74 24 20 57 48 83 EC 60 48 8B F1 48 8B FA 48 83 C1 48 E8, expected: 1, index: 0
#pragma endregion

#pragma region PlayerSystem
constexpr uintptr_t PlayerSystem_OnPlayerSpawned = 0x1427353F0 - ImageBase; // 48 8B C4 4C 89 48 20 55 56 57 48 8B EC 48 81 EC 80 00 00 00, expected: 1, index: 0
constexpr uintptr_t PlayerSystem_OnPlayerSpawned =
0x1403EE038 - ImageBase; // 48 89 5C 24 08 48 89 74 24 18 48 89 7C 24 20 55 41 54 41 55 41 56 41 57 48 8B EC 48 83 EC 60 48 8B 5A 08 B8 01 00 00 00, expected: 1, index: 0
#pragma endregion
} // namespace CyberEngineTweaks::Addresses
Loading

0 comments on commit 465e46f

Please sign in to comment.