-
Notifications
You must be signed in to change notification settings - Fork 137
How to test a game extension
Testing a game extension isn't an exact science but these are some ways to make sure that the extension is going to work on other user's computers as well as make sure that common pitfalls are avoided.
A game extension is never going to support 100% of mods due to the various mod types available, every game being different and the general complexity of modding.
We recommend taking the most popular mods for the game on Nexus Mods (not including reshades or executable installers) and just making sure they work. Not all types of mods will necessarily work but if only a small percentage of the most popular mods work, that isn't good for the users of Nexus and generally causes more complaints and support issues.
If that's the case, come talk to us in Discord (#vortex-dev is ideal for extension chat) and we can help point in the right direction when it comes to code snippets or how to tackle the problem.
It's always good practice, even if slightly awkward, to test the extension on a clean game install and potentially across multiple game stores. This can highlight issues like folders not being created, paths not being relative, games not being discovered.
The next stage after a clean game install is to test on another user's machine where possible, a friend or colleague can help massively with diagnosing common issues. You will have a greater chance than just doing the above to find incompatibilities with folders and stores. To send an extension to another user to test, follow the same steps in How to package a game extension to make sure your archive and files are structured and formatted correctly. You DO NOT need to upload to Nexus at this point, just send the user the archive and ask them to extract it to a folder within the %APPDATA\Vortex\Plugins
folder.
For example
My extension is within an archive called game-name-0.1.0.zip
and I send that to a friend to try it out.
- Press
Windows Key
+R
to bring up the Windows Run box and enter%APPDATA%\Vortex\Plugins
- Extract the
game-name-0.1.0.zip
archive into a folder - You'll end up with
%APPDATA%\Vortex\Plugins\game-name-0.1.0
that looks something like this inside
Start Vortex and it will load the extension the same as if it was downloaded.
These are common problems that we come across during game extension review that will cause them to fail
The top 3 packaging issues we see are:
- Single nested folder as root (all files inside of a single folder in the archive)
- Incorrect version (not being semantic)
- Incorrect gameart (wrong size, containing text)
Please read How to package a game extension for everything you need to know to fix these issues.
In order for the extension to work across any computer, all paths need to be relative and not include absolute paths. A path to a mod folder like c:\games\starfield\mods
generally won't be the same on another user's computer (as they might use a different drive or a different games folder) and so paths need to be relative to the game folder that the extension is managing such as .\mods
.
Vortex doesn't create folders by default when paths are defined. In the example above, the mods
folder within c:\games\starfield
isn't a default game folder and so can't be relied upon to exist.
The best way to make sure that Vortex doesn't try to access a folder that doesn't exist is to create any folder that is referenced by the extension. At a minimum there is what queryModPath
is defined as and also any extra mod types that have been defined tend to have their own paths. The fs.ensureDirWritableAsync()
function can be used to make sure paths exist. See this example to see how ensuring a mods
folder exists within the game root (discovered) folder.
async function setup(api: types.IExtensionApi, discovery: types.IDiscoveryResult): Promise<void> {
try {
// make sure the folder exists
await fs.ensureDirWritableAsync(path.join(discovery.path, 'mods'));
return;
}
catch (error)
{
// show error in vortex ui
api.showErrorNotification('Failed to setup extension', error);
throw error;
}
}
Some games have tools or mods that are needed in order for the majority of mods to work. These can include script extenders (SFSE for Starfield, SKSE for Skyrim) or tools (LSLib for Baldur's Gate 3). During testing, if you find that a dependency like this is needed, then inform the user that they need, or more than likely will need, it in order for mods to work.
It doesn't have to be a complicated download and update system like some of the bigger extensions have (as nice as they are) but from a users perspective, they will download the extension and expect mods to work or be given all the information necessary to get them to work.
A simple notification with what needs to happen is enough to get started.
Example
api.sendNotification({
id: 'mod-required',
type: 'warning',
message: 'This tool is required by most mods',
allowSuppress: true,
actions: [{
title: 'Download',
action: () => util.opn('https://www.reshade.me/').catch(err => undefined);
}],
});
This wiki and the Vortex Readme document contains a lot of information, please take your time and read these instructions carefully.
We provide detailed changes for each Vortex release.
If you have any questions about Vortex usage or want to share some information with the Vortex community, please go to one of the following places:
- About
- Install
- Troubleshooting
- Troubleshooting
- Developers
- Troubleshooting
- Developers
- Valheim
- Bannerlord
- BepInEx
- How to test a game extension
- How to package a game extension
- How to upload an extension to Nexus
- How to submit a game extension for review
Warning
The below documentation has not been checked for quality since migrating to GitHub Wiki and the information contained is potentially out of date and\or repeated.
- Frequently Asked Questions
- Getting Started
- Deployment Methods
- Downloading from Nexus Mods
- Managing File Conflicts
- Managing your Load Order
- Managing Save Games
- Setting up Profiles
- Keyboard Shortcuts
- How to create mod installers
- External Changes
- The Vortex Approach to Load Order
- Moving Vortex to a new PC
- Modding Skyrim Special Edition with Vortex
- Modding Mount & Blade II: Bannerlord with Vortex
- Modding Monster Hunter: World with Vortex
- Modding The Witcher 3 with Vortex
- Modding Baldur's Gate 3 with Vortex
- Modding Stardew Valley with Vortex
- Modding Valheim with Vortex
- Error Messages
- Misconfigured Documents Folder
- .NET 6 Install Issues
- Downgrading Extensions
- Command Line Parameters
- Introduction to Vortex extensions
- Creating a game extension (JavaScript)
- Creating a theme
- Game detection
- Adding a main page
- Adding a load order page
- Building UI with Vortex and React
- Packaging an extension
- Introduction
- Packaging extensions
- Project management
- Harmony Patcher Exectuable
- Vortex Harmony Mod Loader
- Setting up your dev environment
- Creating a theme
- Creating a game extension