Changing User Data storage location
Moderator: Forum Moderators
Forum rules
Before reporting issues in this section, you must read the following topic:
Before reporting issues in this section, you must read the following topic:
Changing User Data storage location
I’m running version 1.14.7 on a Windows 10 machine (a Lenovo Yoga 730-13, to be very, very specific). Back in the olden days, there was an option when installing BfW to have the user data stored in the same location as the game, itself, but that seems not to be available anymore. I’m wondering if there’s a way to do this manually?
More background, because context often matters:
To make my BfW available regardless of what machine I’m using, I’ve installed it in my DropBox. (And yes, Yay!, that works!) I really want to store my saved games and downloads there, as well. Windows 10, however (curse those Redmond Trolls!) insists on storing the information at c:\users\[username]\documents\mygames\wesnoth1.14.
More background, because context often matters:
To make my BfW available regardless of what machine I’m using, I’ve installed it in my DropBox. (And yes, Yay!, that works!) I really want to store my saved games and downloads there, as well. Windows 10, however (curse those Redmond Trolls!) insists on storing the information at c:\users\[username]\documents\mygames\wesnoth1.14.
Re: Changing User Data storage location
You can edit or create a new shortcut for wesnoth.exe with additional options like so:
The quotes surrounding the full path to wesnoth.exe are not optional if there are spaces in any folder names.
Code: Select all
"C:\Users\YourUsername\Dropbox\Wesnoth 1.14\wesnoth.exe" --userdata-dir .\userdata --userconfig-dir .\userdata
Author of the unofficial UtBS sequels Invasion from the Unknown and After the Storm.
Re: Changing User Data storage location
Thanks! I will try that.
Re: Changing User Data storage location
Okay, one thing to know about me is that I’m really slooooooooow (perhaps in more ways than one?), so I’m just now getting around to implementing this.
Problem: I’ve added the suggested language, but it’s not working. Specifically, the shortcut isn’t working at all with that addition. (I.e., it doesn’t open BfW.) Obviously, I’m doing something wrong.
Here’s what I did:
(A) I created a shortcut (you know, right-click on the app wesnoth.exe and choose the option “Create shortcut.”
(B) Opening up the shortcut (right-click, then choose “Properties”), I get a box with multiple tabs and multiple entries, but the default tab is “Shortcut,” which has what I think we’re looking for.
(C) In that tab, there were two specific fields that might be where the information goes. The first, “Target,” is pre-filled with “C:\Users\[my name]\Dropbox\Games\Battle for Wesnoth\wesnoth.exe”. (Quotation marks already included.) The second, “Start in,” is profiled with “C:\Users\[my name]\Dropbox\Games\Battle for Wesnoth”. (Again, already with the quotation marks.) As only “Target” includes the full path, all the way to wesnoth.exe, I thought that’s where it should go, so it now reads:
“C:\Users\[my name]\Dropbox\Games\Battle for Wesnoth\wesnoth.exe” --userdata-dir .\userdata --userconfig-dir .\userdata
(Punctuation and spacing exactly as written.)
Have I missed something that’s obvious to real coders?
EDIT: So . . . a little Google search, and it looks like I needed to add an “=” and take out the space before “.\userdata” — and now it seems to be functioning!
Problem: I’ve added the suggested language, but it’s not working. Specifically, the shortcut isn’t working at all with that addition. (I.e., it doesn’t open BfW.) Obviously, I’m doing something wrong.
Here’s what I did:
(A) I created a shortcut (you know, right-click on the app wesnoth.exe and choose the option “Create shortcut.”
(B) Opening up the shortcut (right-click, then choose “Properties”), I get a box with multiple tabs and multiple entries, but the default tab is “Shortcut,” which has what I think we’re looking for.
(C) In that tab, there were two specific fields that might be where the information goes. The first, “Target,” is pre-filled with “C:\Users\[my name]\Dropbox\Games\Battle for Wesnoth\wesnoth.exe”. (Quotation marks already included.) The second, “Start in,” is profiled with “C:\Users\[my name]\Dropbox\Games\Battle for Wesnoth”. (Again, already with the quotation marks.) As only “Target” includes the full path, all the way to wesnoth.exe, I thought that’s where it should go, so it now reads:
“C:\Users\[my name]\Dropbox\Games\Battle for Wesnoth\wesnoth.exe” --userdata-dir .\userdata --userconfig-dir .\userdata
(Punctuation and spacing exactly as written.)
Have I missed something that’s obvious to real coders?
EDIT: So . . . a little Google search, and it looks like I needed to add an “=” and take out the space before “.\userdata” — and now it seems to be functioning!
Re: Changing User Data storage location
Trying to do the same thing, but I'm having an issue and not sure what it is. (FWIW, this is now version 1.16.8, on Windows.)
"C:\Users\[name]\iCloudDrive\Battle for Wesnoth\wesnoth.exe"--userdata-dir=.\userdata --userconfig-dir=.\userdata
Everything within the quotation marks was pre-written. I added the rest (userdata etc.), putting the "=" in place of spaces. Note this exactly how the Cen7 example was done. (I know, because I have access to his machine.) But when I try to save, I get the error, "The name . . . specified in the Target box is not valid. Make sure the path and file name are correct.
I've tried creating a userdata folder in my wesnoth folder, as well as copying over all the cache, data, etc., files from the My Games folder (and deleting the files in that location). Still the same error. I'm running out of ideas.
EDIT: Seeing this post -- viewtopic.php?t=56549 -- I also tried putting in the *full* pathway to userdata for both the userdata-dir and userconfig-dir commands, trying it both with the "=" signs and with spaces instead of the equal signs. Still the same error.
"C:\Users\[name]\iCloudDrive\Battle for Wesnoth\wesnoth.exe"--userdata-dir=.\userdata --userconfig-dir=.\userdata
Everything within the quotation marks was pre-written. I added the rest (userdata etc.), putting the "=" in place of spaces. Note this exactly how the Cen7 example was done. (I know, because I have access to his machine.) But when I try to save, I get the error, "The name . . . specified in the Target box is not valid. Make sure the path and file name are correct.
I've tried creating a userdata folder in my wesnoth folder, as well as copying over all the cache, data, etc., files from the My Games folder (and deleting the files in that location). Still the same error. I'm running out of ideas.
EDIT: Seeing this post -- viewtopic.php?t=56549 -- I also tried putting in the *full* pathway to userdata for both the userdata-dir and userconfig-dir commands, trying it both with the "=" signs and with spaces instead of the equal signs. Still the same error.
Re: Changing User Data storage location
You seem to be missing space between " and -
Re: Changing User Data storage location
Wow! You're right: that's all it was.
Thank you.
Thank you.
Re: Changing User Data storage location
Consternation! I spoke too soon: adding that space ended the error message and allowed me to "apply" the change, but now the shortcut no longer works: I click on it, and it does nothing. (Same is true if I also right-click on the shortcut and select "run").
Here's the current Target line: "C:\Users\[username]\iCloudDrive\Battle for Wesnoth\wesnoth.exe" --userdata-dir=C:\Users\[username]\iCloudDrive\Battle for Wesnoth\userdata --userconfig-dir=C:\Users\[username]\iCloudDrive\Battle for Wesnoth\userdata
I've tried it with both the "=" and with a space where the "=" is. Same result. (Also tried deleting the shortcut, recreating it and making this edit to Target. Same result.) Undoubtedly, I'm missing something very simple yet again. I just don't know what.
Here's the current Target line: "C:\Users\[username]\iCloudDrive\Battle for Wesnoth\wesnoth.exe" --userdata-dir=C:\Users\[username]\iCloudDrive\Battle for Wesnoth\userdata --userconfig-dir=C:\Users\[username]\iCloudDrive\Battle for Wesnoth\userdata
I've tried it with both the "=" and with a space where the "=" is. Same result. (Also tried deleting the shortcut, recreating it and making this edit to Target. Same result.) Undoubtedly, I'm missing something very simple yet again. I just don't know what.
Re: Changing User Data storage location
That's probably not going to work because you have spaces in your
--userdata-dir
and --userconfig-dir
arguments. So to the program, it looks like the arguments are:
--userdata-dir=C:\Users\[username]\iCloudDrive\Battle
for
Wesnoth\userdata
--userconfig-dir=C:\Users\[username]\iCloudDrive\Battle
for
Wesnoth\userdata
- Probably the simplest thing to do is to just go back to using
.\userdata
, which should work fine - You could rename the folder
Battle for Wesnoth
to something without spaces, likeBattleForWesnoth
or simplyWesnoth
- You might be able to get it to work by using quotation marks
Re: Changing User Data storage location
Thank you. That explains much.
I actually got it working by reverting to the relative(?) reference: --userdata-dir=.\userdata etc.
I'm learning. Thank you for all your help.
I actually got it working by reverting to the relative(?) reference: --userdata-dir=.\userdata etc.
I'm learning. Thank you for all your help.