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
|`UNREALSDK_ENV_FILE`| A file containing environment variables to load, relative to the dll. Defaults to `unrealsdk.env`. More below. |
58
-
|`UNREALSDK_EXTERNAL_CONSOLE`| If defined, creates an external console window mirroring what is written to the game's console. Always enabled in debug builds. |
59
-
|`UNREALSDK_LOG_FILE`| The file to write log messages to, relative to the dll. Defaults to `unrealsdk.log`. |
60
-
|`UNREALSDK_LOG_LEVEL`| Changes the default logging level used in the unreal console. May use either the level names or their numerical values. |
61
-
|`UNREALSDK_GAME_OVERRIDE`| Override the executable name used for game detection. |
62
-
|`UNREALSDK_UPROPERTY_SIZE`| Changes the size the `UProperty` class is assumed to have. |
63
-
|`UNREALSDK_ALLOC_ALIGNMENT`| Changes the alignment used when calling the unreal memory allocation functions. |
64
-
|`UNREALSDK_CONSOLE_KEY`| Changes the default console key which is set when one is not already bound. |
65
-
|`UNREALSDK_UCONSOLE_CONSOLE_COMMAND_VF_INDEX`| Overrides the virtual function index used when hooking `UConsole::ConsoleCommand`. |
66
-
|`UNREALSDK_UCONSOLE_OUTPUT_TEXT_VF_INDEX`| Overrides the virtual function index used when calling `UConsole::OutputText`. |
67
-
|`UNREALSDK_LOCKING_PROCESS_EVENT`| If defined, locks simultaneous ProcessEvent calls from different threads. This is used both for hooks and for calling unreal functions - external code must take care wrt. deadlocks. |
68
-
|`UNREALSDK_LOG_ALL_CALLS_FILE`| After enabling `unrealsdk::hook_manager::log_all_calls`, the file to write calls to. |
69
-
70
-
You can also define any of these in an env file, which will automatically be loaded when the sdk
71
-
starts (excluding `UNREALSDK_ENV_FILE` of course). This file should contain lines of equals
72
-
separated key-value pairs, noting that whitespace is *not* stripped (outside of the trailing
73
-
newline). A line is ignored if it does not contain an equals sign, or if it defines a variable which
74
-
already exists.
75
-
76
-
```ini
77
-
UNREALSDK_LOG_LEVEL=MISC
78
-
UNREALSDK_CONSOLE_KEY=Quote
79
-
```
80
-
81
-
You can also use this file to load environment variables for other plugins (assuming they don't
82
-
check them too early), it's not limited to just those used by the sdk.
50
+
# Integrating the SDK into your project
51
+
So there are a few extra steps to integrate the sdk into your project before you can start using
52
+
hooks like above.
83
53
84
-
# Linking Against the SDK
85
-
The sdk requires at least C++20, primarily for templated lambdas. It also makes great use of
86
-
`std::format`, though if this is not available it tries to fall back to using fmtlib. Linking
87
-
against the sdk thus requires your own projects to use at least C++20 too.
54
+
The SDK requires at least C++20. This is primarily for templated lambdas - you may still be able to
55
+
use it if your compiler doesn't yet fully support it (e.g. it falls back to fmtlib if `std::format`
56
+
is not available).
88
57
89
-
To link against the sdk, simply clone the repo (including submodules), add it as a subdirectory,
90
-
and link against the `unrealsdk` target.
58
+
The recommended way to link against the sdk is as a submodule.
0 commit comments