Page 1 of 1
Mod Directories
Posted: Thu Nov 24, 2016 4:53 pm
by SoulForge
Not sure how feasible this is.
Want to be able to have different mod directories so I can load up a specific set of mods.
Back in the olden quake days you'd have a -game or maybe could use -mod as a command line switch to specific which directory to load from.
Re: Mod Directories
Posted: Thu Nov 24, 2016 5:53 pm
by Artentus
There is a --mod-directory command line switch.
But if I may make a suggestion, this is easier than multiple directories:
viewtopic.php?f=137&t=33370
Re: Mod Directories
Posted: Fri Nov 25, 2016 2:30 pm
by SoulForge
I tried the command line parameter you provided and it didn't seem to work.
That program also didn't work correctly. It created a 0.14 directory in my mods folder with more 0.14 directories about 20 folders deep and then crashed.
EDIT;
Ok that command line parameter did work but it created a directory in the bin folder which I did not expect.
Re: Mod Directories
Posted: Fri Nov 25, 2016 2:47 pm
by daniel34
SoulForge wrote:Ok that command line parameter did work but it created a directory in the bin folder which I did not expect.
You'll need to specify the relative path to the working directory (the "Start in" directory in the properties), see this screenshot (sorry that it's german):

- factorio-properties.png (45.16 KiB) Viewed 5313 times
I just copied the default Factorio shortcut, renamed it to "Modded Factorio (0.14)" and altered the shortcut (Verknüpfung) properties. The working drectory (Ausführen als / Start in, the lower text field) has been
Factorio\bin\x64 already, so the --mod-directory has to go up two folders, this is why the Ziel / Target (upper textfield) is set to
factorio.exe --mod-directory ../../mymods.
The ../../ makes the game ignore the bin\x64 and look for the folder directly in the Factorio directory.
This is my current Factorio directory:

- factorio-properties-2.png (33.52 KiB) Viewed 5320 times
Using the new modded shortcut explained above it will load the mods from the
mymods folder, but when using the original (unchanged) shortcut it will load the mods from the
mods folder, which is empty for vanilla.
EDIT: I just noticed the slashes should be backwards in Windows, e.g. ..\..\, but it seems to work both ways for Factorio.
Re: Mod Directories
Posted: Fri Nov 25, 2016 5:28 pm
by SoulForge
Thank you Daniel.
While a shortcut won't really work due to the portable HD I use. A batch file does the trick nicely using the same thing.
Is there a similar --save-directory command?
I feel as if this would work better if these commands looked for these folders under the already existing directories.
Mods\MyMods as an example.
Maybe merge them together. So saves for MyMods would be found under saves\MyMods.
Not sure if I am explaining this one right.
Re: Mod Directories
Posted: Fri Nov 25, 2016 6:50 pm
by Artentus
A
SoulForge wrote:--save-directory command
does not exist.
But why do you need one? One save directory should suffice.
SoulForge wrote:That program also didn't work correctly. It created a 0.14 directory in my mods folder with more 0.14 directories about 20 folders deep and then crashed.
Let me guess, you selected your existing mods folder as the global mods folder in the settings.
Don't do that, it will try to move the contents of the old directory to the global one which will result in infinite recursion if source and destination are the same. Select an empty directory instead.
You can make ModMyFactory portable by starting it with the parameter --appdata-directory=PATH pointing to a relative location.
Re: Mod Directories
Posted: Fri Nov 25, 2016 7:13 pm
by onebit
I had a
Mod profiles idea.
Re: Mod Directories
Posted: Fri Nov 25, 2016 7:36 pm
by daniel34
SoulForge wrote:While a shortcut won't really work due to the portable HD I use. A batch file does the trick nicely using the same thing.
Is there a similar --save-directory command?
If you really want to have separate mods and saves directories and also have it portable, why not just use the .zip version extracted to two different locations?
https://www.factorio.com/download allows you to download the x64 .zip archive, just extract it to two different folders and you have two different Factorio installations. (Two can be replaced by several, if you need more than two.)
Each of them will be completely independent and only read/write files within their folder, making managing several of them very easy without one influencing the other.
Re: Mod Directories
Posted: Fri Nov 25, 2016 11:34 pm
by ssilk