For installation instructions / the mod database, see the project site.
The pyunrealsdk mod manager for:
- Borderlands 2
- Borderlands: The Pre-Sequel
- Tiny Tina's Assault on Dragon Keep Standalone
When developing, it's recommended to point pyunrealsdk directly at this repo. To do this:
-
Navigate to the plugins folder -
<game>\Binaries\Win32\Plugins\
-
Create/edit
unrealsdk.user.toml
, adding the following:[pyunrealsdk] init_script = "<path to repo>\\src\\__main__.py"
-
(Optional) Update
pyunrealsdk.pyexec_root
to the same folder, to make sure pyexec commands go where you expect. -
(Optional) Add the path to your old
sdk_mods
folder to themod_manager.extra_folders
array, so they continue getting loaded. -
(Optional) Copy/symlink your original settings folder into
src\settings
- settings are only loaded from the base mods folder.
Once you've done this, you can modify the python files in place.
The mod manager currently doesn't rely on any native modules. You may however still want to edit/debug the base pyunrealsdk code while working on this project. To do this:
-
Initialize the git submodules.
git submodule update --init --recursive
You can also clone and initialize the submodules in a single step.
git clone --recursive https://github.com/bl-sdk/willow2-mod-manager.git
-
Make sure you have Python with requests on your PATH. This doesn't need to be the same version as what the SDK uses, it's just used by the script which downloads the correct one.
pip install requests python -c 'import requests'
If not running on Windows, make sure
msiextract
is also on your PATH. This is typically part of anmsitools
package.apt install msitools # Or equivalent msiextract --version
See the explicit python readme for a few extra details.
-
Choose a preset, and run CMake. Most IDEs will be able to do this for you,
cmake . --preset msvc-debug cmake --build out/build/msvc-debug
-
(OPTIONAL) If you need to debug your module, and you own the game on Steam, add a
steam_appid.txt
in the same folder as the executable, containing the game's Steam App Id.Normally, games compiled with Steamworks will call
SteamAPI_RestartAppIfNecessary
, which will drop your debugger session when launching the exe directly - adding this file prevents that. Not only does this let you debug from entry, it also unlocks some really useful debugger features which you can't access from just an attach (i.e. Visual Studio's Edit and Continue).