-
Notifications
You must be signed in to change notification settings - Fork 16
ModIO.ModManager.TryInstallMod
ModManager.TryInstallMod
public static bool TryInstallMod(int modId, int modfileId, bool removeArchiveOnSuccess);
Name | Description |
---|---|
modId | Mod identifier of the mod binary to install |
modfileId | Modfile identifier of the mod binary to install |
removeArchiveOnSuccess | Remove the mod binary archive be removed if the installation succeeds |
bool: TRUE indicates the entire installation completed successfully, (although the failure/success of the achive deletion is unchecked). FALSE indicates that either the mod binary archive does not exist, the uninstallation of previous versions failed, or that the extraction process failed.
Extracts a mod archive to the installs folder and removes other installed versions.
This function does not manage the downloading of mod binaries, merely extracts the mod binary zip file stored at the location described by CacheClient.GenerateModBinaryZipFilePath. If this file does not exist, or is not an extractable archive, this this function will fail. Additionally, if any existing modfile installations fail to uninstall, this function will also fail.