Fixes "Error: Access to the path ..." error when loading a savegame
Permissions and credits
Credits and distribution permission
Other user's assetsAll the assets in this file belong to the author, or are from free-to-use modder's resources
Upload permissionYou are not allowed to upload this file to other sites under any circumstances
Modification permissionYou must get permission from me before you are allowed to modify my files to improve it
Conversion permissionYou are not allowed to convert this file to work on other games under any circumstances
Asset use permissionYou must get permission from me before you are allowed to use any of the assets in this file
Asset use permission in mods/files that are being soldYou are not allowed to use assets from this file in any mods/files that are being sold, for money, on Steam Workshop or other platforms
Asset use permission in mods/files that earn donation pointsYou are not allowed to earn Donation Points for your mods if they use my assets
Author notes
This author has not provided any additional notes regarding file permissions
File credits
This author has not credited anyone else in this file
Donation Points system
This mod is not opted-in to receive Donation Points
Changelogs
Version 1.0.0
Initial version
Description This mod fixes a bug that can happen if a large savegame has already been loaded (whether you are still in that game, or have exited to the main menu) and you try to load another savegame. The same bug also causes it to be necessary to press "Exit Game" and confirm exiting twice when a large game has already been loaded.
Details The bug happens when the game tries to "unload" the current game, which involves deleting and recreating a cache-folder (the one mentioned in the error message). Because of the way this is done, it can attempt to recreate the folder before it has been fully deleted which will cause the error. This mod fixes it by patching the method handling this deletion and recreation, so that the folder is renamed before deletion to prevent the deletion taking a little bit of time affecting the recreation of it.
Thanks to hsinyuhcan for helping me get started with Harmony Transpile patching.