Hi there! You are currently browsing as a guest. Why not create an account? Then you get less ads, can thank creators, post feedback, keep a list of your favourites, and more!

Documents Override (Windows only)

SCREENSHOTS
4,330 Downloads 69 Thanks  Thanks 30 Favourited 16,010 Views
Uploaded: 15th Aug 2021 at 6:10 PM
What is it for?
This tool can override the Documents path used by the game. You can also create multiple profiles, each using a different path. This is useful if you want to keep your mods on a drive with more space or if you want a separate profile for some challenge.

Short instructions
  1. Extract files to the same folder as the game exe.
  2. Edit "documents.ini".
  3. Add "-profile=profile name" to the shortcut's target where "profile name" matches the section in the ".ini" file.

Detailed instructions
  1. Download the correct archive. (normal The Sims 4 is 64-bit, Legacy Edition is 32-bit)
  2. Extract it. There are 4 files in each archive.
  3. First open your game folder. By default:
    • Origin installs the game to "C:\Program Files (x86)\Origin Games\The Sims 4"
    • Steam installs the game to "C:\Program Files (x86)\Steam\steamapps\common\The Sims 4"
    Then open the folder with your game exe:
    • normal version of the game is in "Game\Bin"
    • Legacy Edition is in "Game\Bin_LE"
  4. Move the 4 extracted files to where your game exe is.
  5. Edit "documents.ini" file to your liking:
    • if you want to change the default folder uncomment (remove ";") line 4 (see the screenshot below) and set it to desired path
    • if you want to use another profile edit the existing ones or add a new one:
      Code:
      [profile name]
      Documents=folder path
You can use a different profile by editing your game shortcut. But first you need to create a new one:
  1. Right click on the game exe ("TS4_x64.exe" for the normal version, "TS4.exe" for the Legacy Edition), select "Send to" and then "Desktop".
  2. Go to desktop.
  3. Right click on the new shortcut, select Properties.
  4. At the end of the "Target" field add a space and then "-profile=profile name", where "profile name" is the name of the profile you added to the "documents.ini". See the green underlines on the screenshot below.



How does it work?
First of all my tool needs to be somehow loaded into the game. For this I use Ultimate ASI Loader, version 4.59 (archived link in case the previous one goes down). That's where "version.dll" comes from. "version.ini" is a config file for ASI Loader.

"documents.ini" is a config file for my tool. And the main brains is of course the last file, "documents.asi". It's a normal DLL file with extension renamed to ".asi" (that's what ASI Loader looks for). The game uses "SHGetFolderPathW" function to find the Documents path. My tool hooks to that function and spoofs the response. That's pretty much it.