You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/guides/fixing-compatibility-problems-advanced.md
+30-58Lines changed: 30 additions & 58 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,51 +1,53 @@
1
1
# Fixing Missing AOBs (Advanced & In-Depth)
2
2
3
-
When UE4SS fails to properly launch due to missing AOBs (Array of Bytes signatures), you can provide custom AOBs and callback functions using Lua. Doing so, however, requires a level of reverse engineering knowledge and tooling setup that may feel complex at first. This guide expands upon the original instructions, providing even more detail, context, and recommended best practices.
3
+
When UE4SS fails to properly launch due to missing AOBs (Array of Bytes signatures), you can provide custom AOBs and callback functions using Lua.
4
+
Doing so, however, requires a level of reverse engineering knowledge and tooling setup that may feel complex at first.
5
+
This guide expands upon the original instructions, providing more detail, some context and tips.
4
6
5
7
## Prerequisites
6
8
7
9
-**Knowledge of Basic Reverse Engineering Concepts:**
8
10
You should have a general idea of what a signature (AOB) is, how to use a debugger, and how to navigate memory in x64dbg.
9
-
10
-
-**Understanding ‘root directory’ and ‘working directory’:**
11
-
-**Root directory:** The directory containing `ue4ss.dll`.
12
-
-**Working directory:** This can be either the root directory **or** a game-specific directory such as `<root directory>/SatisfactoryEarlyAccess`.
13
11
14
12
-**Familiarity with UE4SS Setup & Directories:**
15
-
Make sure you know where `UE4SS_Signatures` folder should be created (it should be next to `ue4ss.dll` or in a game-specific working directory as described above).
13
+
Make sure you know where the `UE4SS_Signatures` folder should be created (it should be next to `ue4ss.dll` or in a game-specific working directory).
16
14
17
15
-**Preparation and Tools Installed:**
18
16
-**Epic Games Launcher & Unreal Engine:** For creating a “blank shipped game” environment with the correct engine version.
19
17
-**x64dbg:** A debugger tool for Windows (https://x64dbg.com/).
20
18
-**(Optional) Baymax Tools:** A plugin to help generate signatures easily.
21
-
-**(Optional) Swiss Army Knife (by Nukem9):** For extracting signatures.
19
+
-**(Optional) Swiss Army Knife (by Nukem9):** For more easily extracting signatures with correct wildcards.
22
20
23
-
## Why Create Your Own AOBs?
21
+
## When is this needed, and why ?
24
22
25
-
When UE4SS updates or when you attempt to mod a game with a newer or unusual engine build, official AOB signatures inside UE4SS may fail. In these cases, providing your own AOBs and callbacks allows UE4SS to locate critical engine functions and global variables in memory and resume normal operation.
23
+
Some games don't use Unreal Engine with its default configuration, and we only support the default configuration out of the box.
24
+
Anything that affects the code generated by the compiler, including the devs using Clang instead of MSVC, can make our built-in AOBs no longer be valid.
25
+
These AOBs are used to find functions and variables that are critical for UE4SS to work.
26
26
27
27
## High-Level Overview
28
28
29
29
1.**Identify Which Signatures Are Missing:** Determine which functions or variables UE4SS cannot find (e.g., GUObjectArray, GMalloc, FName or FText constructors).
30
-
2.**Set Up a Reference Environment:** Create a blank Unreal Engine shipped game with debug files (PDBs) that matches your game’s Unreal Engine version. This environment helps you identify function signatures cleanly.
31
-
3.**Reverse Engineer and Extract AOBs:** Using x64dbg (and optional plugins), open the shipped game and locate the desired function in memory. Copy out the unique bytes that form a reliable signature.
30
+
2.**Set Up a Reference Environment:** Create a blank Unreal Engine game (using the Shipping target) with debug files (PDBs) that uses the same Unreal Engine version as your game. This environment helps you identify function signatures cleanly.
31
+
3.**Reverse Engineer and Extract AOBs:** Using x64dbg (and optional plugins), open the blank game and locate the desired function in memory. Copy out the unique bytes that form a reliable signature. This signature should be properly wildcarded, if it's not, it won't be found in your game.
32
32
4.**Apply Your Signatures to the Actual Game:** Attach x64dbg to the target game, find the matching bytes, and confirm that the signature you extracted matches code in the game you want to mod.
33
33
5.**Create a Lua Script:** Write a Lua file in `UE4SS_Signatures` to tell UE4SS what AOB pattern to search for (through `Register`) and what final address to return (through `OnMatchFound`).
34
34
35
35
## Finding AOBs: A More Detailed Explanation
36
36
37
37
> [!CAUTION]
38
-
> Reverse engineering these signatures isn’t trivial. You may need to step outside the scope of this guide, read reverse-engineering tutorials, or ask for community support. The steps below are a starting point, not a complete primer on reverse engineering.
38
+
> Reverse engineering these signatures isn’t trivial. You may need to step outside the scope of this guide, read reverse-engineering tutorials, or ask for community support. The steps below are a starting point, not a complete guide on reverse engineering.
39
39
40
40
### Step 1: Determine Your Game’s Unreal Engine Version
41
41
42
-
UE4SS tries to detect the engine version automatically. If you need to verify:
42
+
UE4SS tries to detect the engine version automatically. If you need to verify, the following steps usually work:
43
43
44
44
- Right-click on the game’s `.exe` file (often in `Binaries` folder).
45
45
- Select **Properties** -> **Details** tab.
46
46
- Look for the “File Version” or “Product Version” field, which often correlates to the Unreal Engine version.
47
47
48
-
For example: If it says `5.3.2.0`, it likely corresponds to UE 5.3.2.
48
+
For example: If it says `5.3.2.0`, it likely corresponds to UE 5.3.2.
49
+
In rare cases, the version will either be empty, or it will refer to the game version instead of the engine version.
50
+
Note that the last number doesn't usually matter, so if your game is using UE 5.3.2, your blank game can generally use any 5.3 version.
49
51
50
52
### Step 2: Installing the Matching Unreal Engine Version
51
53
@@ -56,7 +58,7 @@ For example: If it says `5.3.2.0`, it likely corresponds to UE 5.3.2.
56
58
57
59
1. Launch the installed Unreal Engine version.
58
60
2. In the New Project window, select the **Games** tab -> **Blank** template.
59
-
- Uncheck “Starter Content” if you prefer a minimal project.
61
+
- Uncheck “Starter Content” because it's not needed, and unchecking this will save time and space.
60
62
- Name your project and specify a directory.
61
63
3. Once created, open **Platforms** -> **Packaging Settings**, and enable “Include Debug Files in Shipping Builds”.
62
64
4. From **Platforms** -> **Windows**, select “Shipping” configuration (or whichever build matches your target game’s build type).
@@ -84,6 +86,10 @@ You need to know which function or variable you’re trying to match in your tar
84
86
85
87
### Step 6: Locating the Function in x64dbg
86
88
89
+
Note that there's a bug in x64dbg where navigating to code or memory from the symbols tab sometimes doesn't work properly.
90
+
If you're navigating and not seeing what you expect, it's worth restarting x64dbg and trying again.
91
+
You can also try copy the address from the symbols tab and manually navigate to it in the correct panel in the CPU tab.
92
+
87
93
1. In x64dbg, switch to the **Symbols** tab.
88
94
2. In the left pane, select the `.exe`.
89
95
3. In the right pane, search for the function name (e.g., `FMemory::Free`).
@@ -93,7 +99,7 @@ You need to know which function or variable you’re trying to match in your tar
93
99
94
100
Once you’ve identified the start of the function, you need to copy a unique sequence of bytes:
95
101
96
-
1. Consider installing [Baymax Tools](https://github.com/sicaril/BaymaxTools) for x64dbg to ease signature extraction.
102
+
1. Consider installing [Baymax Tools](https://github.com/sicaril/BaymaxTools)or Swiss Army Knife for x64dbg to ease signature extraction.
97
103
2. Highlight a set of instructions at the start of the function.
98
104
- Right-click -> **Copy** -> **Selection (Bytes only)** to get a raw byte sequence.
99
105
- With Baymax Tools: Right-click -> **Baymax Tools** -> **Copy Signature** for a ready-made signature pattern.
@@ -116,7 +122,8 @@ Now that you have a reference signature, you need to find it in your target game
116
122
- Try patterns generated by Baymax Tools.
117
123
- Compare and contrast instructions between the blank project and the actual game to locate a similar code region.
118
124
119
-
If you find a match, you’ve identified the address that corresponds to the target function or variable in the actual game. If you can’t find it, you may need to refine your signature, pick a different part of the function, or ask for community help (UE4SS Discord or GitHub Issues).
125
+
If you find a match, you’ve identified the address that corresponds to the target function or variable in the actual game.
126
+
If you can’t find it, you may need to refine your signature, pick a different part of the function, or ask for community help (UE4SS Discord or GitHub Issues).
120
127
121
128
### Step 9: Applying the Signature in UE4SS
122
129
@@ -154,48 +161,12 @@ end
154
161
- That your AOB is correct and unique.
155
162
- That `OnMatchFound` returns the correct final address.
156
163
157
-
If still stuck, consider posting detailed steps, logs, and code snippets to the UE4SS community channels. The more detail you provide, the more likely someone can guide you to a solution.
158
-
159
-
## What ‘OnMatchFound’ Should Return
160
-
161
-
Recap of the required returns for each known signature type:
162
-
163
-
-**GUObjectArray:** Return the exact address of the `GUObjectArray` global variable.
164
-
-**FName_ToString:** Return the start address of the `FName::ToString` function.
165
-
-**FName_Constructor:** Return the start address of `FName::FName`. Multiple versions might exist (e.g., for `char*` and `wchar_t*`), but UE4SS validates the correct one internally.
166
-
-**FText_Constructor:** Return the start address of `FText::FText`.
167
-
-**StaticConstructObject:** Return the start address of the `StaticConstructObject_Internal` global function.
168
-
-**GMalloc:** Return the address of the global `GMalloc` variable. Typically found by scanning around `FMemory::Free` and resolving a MOV instruction.
[See the regular guide](./fixing-compatibility-problems.md#how-to-setup-your-own-aob-and-callback).
199
170
200
171
## Tips, Tricks, and Troubleshooting
201
172
@@ -205,4 +176,5 @@ end
205
176
-**Check Offsets Carefully:** Off-by-one or incorrect indexing is a common issue. Double-check your calculations.
206
177
-**Manual Verification:** Sometimes running the blank project again in x64dbg and comparing with the target game’s memory can highlight discrepancies.
207
178
208
-
By following these expanded steps and leveraging the provided tools, you’ll have a more comprehensive understanding of how to fix missing AOBs with UE4SS. Although still complex, this extended guide should help clarify the process and offer practical insights for both beginners and experienced modders venturing into reverse engineering territory.
179
+
By following these expanded steps and leveraging the provided tools, you’ll have a more comprehensive understanding of how to fix missing AOBs with UE4SS.
180
+
Although still complex, this extended guide should help clarify the process and offer practical insights into the reverse engineering territory.
Copy file name to clipboardExpand all lines: docs/guides/fixing-compatibility-problems.md
+1-51Lines changed: 1 addition & 51 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -20,57 +20,7 @@ Since the process is quite complicated, here will just cover the general steps y
20
20
5. Open your game's memory in x64dbg and search it for the same block of bytes
21
21
6. If you find it, you can use the [swiss army knife](https://github.com/Nukem9/SwissArmyKnife) tool to extract the AOB for it which you can use in a simple script such as example [here](#example-script-simple-direct-scan)
22
22
23
-
### Context and definitions
24
-
25
-
Some context and definitions:
26
-
27
-
In this context, a `Signature` refers to a unique sequence or pattern of bytes used to identify a function or piece of code within a binary, such as specific instructions or constants that are unlikely to appear elsewhere. It serves as a recognizable "fingerprint" to locate a particular routine during reverse engineering or patching.
28
-
29
-
In contrast, a `Block of Bytes` is simply a contiguous sequence of raw data or instructions without any specific identification purpose. A block of bytes may or may not represent anything meaningful or unique, whereas a signature is carefully chosen to reliably distinguish a particular function or code segment.
30
-
31
-
`RIP (Instruction Pointer Register)` is a register in x86-64 architecture that holds the address of the next instruction to be executed. It plays a key role in managing program flow, enabling the CPU to keep track of where it is in the program code.
32
-
33
-
Now for each step in more detail (thanks for `TimeMaster` for these steps).
34
-
35
-
### Making a blank shipped game
36
-
37
-
1. Get your game UE version. UE4SS detects it. But it can also be checked by using right-click on the `.exe` in `Binaries`, opening properties and checking on the details tab
38
-
2. In the Epic Games launcher at the left side, go to Unreal Engine -> Library tab at the top and install engine version for the engine version for your game
39
-
3. Once installed launch Unreal Engine. Games tab -> Select Blank -> Uncheck Starter Content (Optional to set a Project Name / change location) -> Create
40
-
4. Press Platforms button on the top bar -> Packaging Settings -> Check `Include Debug Files in Shipping Builds`
41
-
5. Press Platforms button on the top bar -> Windows -> Select `Shipping` (or the one that applies to your game build) -> Package Project and select a folder
42
-
6. Check that the newly packaged blank project contains a `.exe` along with a `.pdb` in `Binaries` in the selected folder
43
-
44
-
### Reading the game's memory using x64dbg
45
-
46
-
1. Install [x64dbg](https://x64dbg.com/)
47
-
2. Run the `.exe` at the root folder of the newly packaged blank project (running the `.exe` in `Binaries` might throw an error, running from root works too either way)
48
-
3. Open x64dbg -> File -> Attach -> Select the newly packaged blank project `.exe` (the one with the path at `Binaries`)
49
-
50
-
### Look for the signature you need
51
-
52
-
1. (Optional but recommended) Connect Epic Games with Github. Login in the Epic Games Website -> Manage Account -> Apps and Accounts -> Github -> Once done, check email and accept invitation to the UE project
53
-
2. (Optional but recommended) Check the source code for the function that is intended to be found in memory. For example, to find the `FMemory::Free` function in a UE5.3.2 game, you would find [this](https://github.com/EpicGames/UnrealEngine/blob/5.3.2-release/Engine/Source/Runtime/Core/Public/HAL/FMemory.inl#L142)
54
-
3. In x64dbg go to Symbols tab -> In the left window select the `.exe` -> Under the right window search for the function (in this case `FMemory::Free`) -> Double click the found Function in the right window
55
-
4. You should be now back at the CPU tab with the address in memory of the start of the selected function
56
-
57
-
### Grab a copy of bytes from the function
58
-
59
-
1. (Optional but recommended) Install [Baymax ToOls](https://github.com/sicaril/BaymaxTools) plugin for x64dbg
60
-
2. Select some (This is where it is not the same for every game and required magic/"knowledge" starts) address lines -> Right Click -> Copy -> Selection or Selection (Bytes only)
61
-
3. If Baymax ToOls installed, while selecting all the addresses lines composing the function -> Right Click -> Baymax ToOls -> Copy Signature.
62
-
4. Might want to copy both selection types and save them in a file for comparison and reference
63
-
64
-
### Open your game's memory in x64dbg
65
-
66
-
1. Open the game you want to mod
67
-
2. Attach x64dbg as seen before with the blank project
68
-
3. Search for the saved block of bytes found in the last step
69
-
4. (If nothing found) Search for the pattern from Baymax ToOls
70
-
5. (If nothing found) Try searching parts of the block of bytes (or signature from Baymax ToOls) and compare the addresses block with the one from the blank project
71
-
6. If nothing found, it might be worth to ask for help on the UE4SS discord or Github issues. Make sure you post all your steps and as much detail as you can provide, otherwise no one will be inclined to help you!
72
-
7. If found a good match, create the lua script to retrieve the address of the function/variable required. Put it in `UE4SS_Signatures` folder in the `Binaries` of your game folder where UE4SS is installed
73
-
8. Run the game and UE4SS hopefully works now
23
+
For more in-depth instructions, see the [advanced guide](./fixing-compatibility-problems-advanced.md).
0 commit comments