SimonC

Change "Prepar3D v4 Add-ons" dir

Recommended Posts

Hello,

I hope this is just something I am quickly missing... I would like to change the default "D:\Documents\Prepar3D v4 Add-ons" directory. As in, I don't want P3D to save it's own "Prepar3D v4 Add-ons" dir into my documents folder. (note that on my computer "Documents" is on D:\Documents)

I know I could work with symlink for instance, but I would hope for a simpler solution, I would like to control that from P3D.

Any chance?

Thanks

Share this post


Link to post
Help AVSIM continue to serve you!
Please donate today!

What are you trying to achieve?  P3D is probably using Windows API calls to retrieve the location of user documents, so there are a lot of things you could mess up here with trying to work around it.

Share this post


Link to post

Yes, I know all too well about that - and that is why I would not like to mess with it outside of P3D, but rather tell P3D where to have that folder.

What I am trying to achieve is simple actually. With the new scenery design of having add-on.xml placed there, one is almost forced to place files there too, but if your disk-concept is different, then you might have a problem with that. Given the wish that I have a single SSD for sim only, I also want all my scenery there, even if in the separate folder. Of course, it would all be the same if you had one single drive. Which I don't... and my D:\Documents\ is where User-Docs reside, and E:\P3D and E:\P3DAddons is where actual P3D files are. Since devs are usually pointing to D:\Documents\Prepar3D v4 Add-ons, it would be nice if P3D where to allow this to be defined and addons then read the set path. I don't see the reason that this folder *MUST* be in User-Docs.

Share this post


Link to post

Can it be done? Yup. Is it a good idea? Nope.  

There is NO reason to put the files there also, just the xml file. You really have nothing to gain other than personal preference and could possible cause you more grief than it's worth.

 

Vic

Share this post


Link to post

As you mentioned, just set up a symlink. As far as windows is concerned, there's absolutely no difference though I wouldn't recommend it for a regular user. 

While I'm all for the new add-on.xml concept, I find it a bit odd that it uses the documents folder as the location. It wouldn't be so bad if it was just for the xml files as intended. However, some devs install all the data to their documents/addon folder which winds me up just a little bit... :D

Share this post


Link to post

No regular user here, working with servers and lots of workstations on daily basis (sysadmin).

Quote

While I'm all for the new add-on.xml concept, I find it a bit odd that it uses the documents folder as the location. It wouldn't be so bad if it was just for the xml files as intended. However, some devs install all the data to their documents/addon folder which winds me up just a little bit... :D

That.

Share this post


Link to post
2 hours ago, Ebs said:

However, some devs install all the data to their documents/addon folder which winds me up just a little bit... :D

Very easy to fix. Move the files where you want and change the path in the xml file. The only caveat is if the dev uses indirect addressing ( ../../) in a control file. You'll find ouot quickly - it will either work or not. If not, move files back.

I would also complain to the dev - the documents folder is for the xml file not data files and IMHO, makes the dev look a little lazy.

Vic

Share this post


Link to post
10 hours ago, vgbaron said:

Very easy to fix. Move the files where you want and change the path in the xml file. The only caveat is if the dev uses indirect addressing ( ../../) in a control file. You'll find ouot quickly - it will either work or not. If not, move files back.

The other caveat is that when there's an update for that addon, it'll either fail because it can't find the original files or it'll go ahead and install new files to the documents folder. Again, a potential mess for the 'regular' user.

What I've found so far is three types of approach that developers take and I'll name names! (not an exhaustive list of course)

1. Install everything 'the old way' directly into the P3D install folder. (PMDG, Majestic, Orbx) 

2. Use add-on.xml but ALSO install all the data to the addon folder: (UK2000)

3. Use add-on.xml and install data to user defined location. (FsDreamTeam, Flightbeam)

There's also a weird 4th option. The dev uses add-on.xml BUT installs the data somewhere in the P3D install path (Drzewiecki)

I believe LM are trying to completely separate the addons from the main install. So, if you wipe your P3D install, your addons remain intact. Right now though, there's a long way to go until more developers start using the new system. I think we'll see more of that as support for FSX (FSX:SE) starts to be phased out.

Share this post


Link to post

You are going to brake something for sure.

I don't get the obsession with these kind of things, I just spent 5 days helping one of my customers with AI lights not working and it was all because he was fiddling with all his add-on's locations and creating XML files that caused a massive conflict with all the Simulator system textures.

Developers design their add-on's in a way to warranty their tools will work, changing variables like this never ends well.

Simbol 

Share this post


Link to post

@simbol I've just installed your freeware product and you're one of the few developers I've seen who use the add-on.xml the way it's meant to be used. Much respect for that.

As for people messing about with this I totally understand. Before I installed v4 I had 2 SSDs in my system. One was a tiny 120GB windows SSD and the other a big 500GB SSD for all my sim files. This served me well, although I did have to spend some time managing other applications due to the fact I always had very little space remaining on my C drive. But, I made sure to keep any and all sim files off my Windows C drive. Before v4 I purchased an additional 500GB SSD to use for my C drive and retired the old 120GB one.

If I was still using the 120GB, you can be sure I'd be making my own add-on.xml files for those developers that insist on installing all their data in my Documents folder (on the C drive). Purely just for managing disk space.

I edited my previous reply as I had stated A2A and FSL do the 'option 2' concept. I've since done a bit of reading and it appears FSL allows you to not install in Documents (but Documents is the default) I'm still not sure about A2A

  • Upvote 1

Share this post


Link to post

You guys have given me a headache just reading it.:biggrin:

Just done a flight into EDDM, if you want bad weather and 30kt winds, low vis, go for it, I need a rest. :cool:

  • Upvote 1

Share this post


Link to post
2 hours ago, Ebs said:

What I've found so far is three types of approach that developers take and I'll name names! (not an exhaustive list of course)

1. Install everything 'the old way' directly into the P3D install folder. (PMDG, Majestic, Orbx) 

2. Use add-on.xml but ALSO install all the data to the addon folder: (UK2000)

3. Use add-on.xml and install data to user defined location. (FsDreamTeam, Flightbeam)

There's also a weird 4th option. The dev uses add-on.xml BUT installs the data somewhere in the P3D install path (Drzewiecki)

I believe LM are trying to completely separate the addons from the main install. So, if you wipe your P3D install, your addons remain intact. Right now though, there's a long way to go until more developers start using the new system. I think we'll see more of that as support for FSX (FSX:SE) starts to be phased out.

Why those top-tier addon-devs can't change their paths, is beyond me. But, I also tested yesterday, what happens if I set couple of addons externally (those that support it) and wipe my P3D. Most went well, but FSL, which is also "outside", didn't work afterwards. Had to reinstall it.

UK2000 gives you an option to install scenery-data into separate location.

It's not only the way till devs start using the new system, the way is even longer until they start using it correctly. I sometimes have a feeling we users teach devs how to use it...

I also started doing what someone else mentioned, is to install into dummy-p3d-folder, and then created my own add-on.xml with Lorby-SI's tool. I'm now in a process of trying to install all my sceneries with the new system.

Share this post


Link to post
1 hour ago, SimonC said:

I also started doing what someone else mentioned, is to install into dummy-p3d-folder, and then created my own add-on.xml with Lorby-SI's tool. I'm now in a process of trying to install all my sceneries with the new system.

I am very against this, most users don't understand that the XML technique is designed for developers to override the simulator preference to resolve textures, effects, sceneries, shaders, etc. And of course other things.

From the few people that have contacted me with issues with my AI lights add-on's, 80 percent of these users have messed up PD3V4 with wrongly implemented XML files!!.

I already have said this on others topics on Avsim and others developers also added information on top of my explanation.

XML files edition only give developers like me headaches when users damage their systems and contact us saying ours tools don't work.

If your add-on's don't support the XML method (mines do), contact your developer and ask they  to move on to the new requirements from LM, don't play to be a developer thinking you can convert their tools by magic XML documents, because most of the time these developers haven't done it because their tools are not ready for it yet.

This is my advise from the other side of the coin.

All the best,

Simbol 

 

Share this post


Link to post

Hello,

Is there any way to transfer the Prepar3d v4 Addons folder from my documents to another drive ? Even if I select a different folder during installation, the addons end up in the v4 add-ons folder in my documents.

Thanks

Share this post


Link to post
Quote

From the few people that have contacted me with issues with my AI lights add-on's, 80 percent of these users have messed up PD3V4 with wrongly implemented XML files!!

So what was really wrong? From a technical aspect.

And believe me, I am probably one of the rarest users, who actually go all the way when troubleshooting. If I have a problem with a tool, aircraft or scenery, then yes, I will post a question somewhere, asking if I am the only one, but I will also go all the way as to uninstall my sim, and run it basic, as to ascertain that my problem is coming from the tool, aircraft or scenery itself. I do this very easily with imaging, since I have more drives, making a restore not a 4 hour process.

Share this post


Link to post

They copied multiple versions of the same files, textures, effects, etc. all over the place and reference them multiple times inside multiple directories on multiple XML files.

Recipe for disaster as PD3V4 will override the texture and effect loading engine using the last entry read on the last XML .

You need to read the SDK in order to understand this, the XML method was designed for developers not end users.

Lots of people disagree and that is fine, it is a free world.

Regards,

Simbol 

 

Share this post


Link to post
3 minutes ago, simbol said:

They copied multiple versions of the same files, textures, effects, etc. all over the place and reference them multiple times inside multiple directories on multiple XML files.

Recipe for disaster as PD3V4 will override the texture and effect loading engine using the last entry read on the last XML .

Actually, I did read what there is about the new .xml system. Not a dev, but I have some understanding about it. I actually started making those files by hand, before the tool was available.

But thank you for the warning, I'll sure keep in mind what you said, I'll include that into my "list" of things I'll look at, if things go south.

Share this post


Link to post
3 minutes ago, SimonC said:

But thank you for the warning, I'll sure keep in mind what you said, I'll include that into my "list" of things I'll look at, if things go south.

You are welcome.

Best of luck.

Simbol 

Share this post


Link to post
2 hours ago, simbol said:

You need to read the SDK in order to understand this, the XML method was designed for developers not end users.

Lots of people disagree and that is fine, it is a free world.

Yeah, the reason i disagree is there are plenty of computer savy users.  This hobby is full of end users that build their own systems and maybe even spend time with 3DSMax and Visual Studio... I'm not a developer and don't pretend to be but understanding an XML file is one of the easiest things I can imagine.  My impression is that a developer to take such an attitude is a little bit like self promotion.

As for where stuff goes on my machine, all my non-Orbx scenery addons use the xml method regardless of how the developer installs it. I put restrictions on what I allow, for example most will create folders for each product which I modify to one folder for each developer and all their products go in the same xml file.  Less clutter.  Also, if the developer opts out of the auto discovery method I will undo that and force it into my method such that all addons are done the same way with the exception of 12bPilot's SODE which has a logical framework and works so I leave alone. Maybe it's my OCD but I don't allow developers like FSDT to list both scenery and texture components.  All my scenery component paths are to the folder the contains the scenery and texture subfolders and with over 100 addons this seems to work well enough.  Just keep it simple and uniform.  My practices work for all scenery except Orbx of course and I suspect they will start using the xml method in the future just as I think PMDG will too... they have had a full plate just keeping up with multiple platforms and did not want to change their installer method in the middle of that.

Share this post


Link to post
1 minute ago, downscc said:

My impression is that a developer to take such an attitude is a little bit like self promotion.

I am heavily offended by your comments, how I am self promoting myself by trying to avoid people from damaging their simulation environment?

I am just helping people on this forum, specially because the lack of understanding of the SDK XML method is causing havoc all over the place.

And in my personal opinion I don't think you understand the full consequences of XML entries, in any case we can agree to disagree, but by any means is not helpful to start personal vendettas just because someone thinks different from you.

Best Regards,

Simbol 

  • Upvote 1

Share this post


Link to post
49 minutes ago, downscc said:

Yeah, the reason i disagree is there are plenty of computer savy users.  This hobby is full of end users that build their own systems and maybe even spend time with 3DSMax and Visual Studio... I'm not a developer and don't pretend to be but understanding an XML file is one of the easiest things I can imagine.  My impression is that a developer to take such an attitude is a little bit like self promotion.

As for where stuff goes on my machine, all my non-Orbx scenery addons use the xml method regardless of how the developer installs it. I put restrictions on what I allow, for example most will create folders for each product which I modify to one folder for each developer and all their products go in the same xml file.  Less clutter.  Also, if the developer opts out of the auto discovery method I will undo that and force it into my method such that all addons are done the same way with the exception of 12bPilot's SODE which has a logical framework and works so I leave alone. Maybe it's my OCD but I don't allow developers like FSDT to list both scenery and texture components.  All my scenery component paths are to the folder the contains the scenery and texture subfolders and with over 100 addons this seems to work well enough.  Just keep it simple and uniform.  My practices work for all scenery except Orbx of course and I suspect they will start using the xml method in the future just as I think PMDG will too... they have had a full plate just keeping up with multiple platforms and did not want to change their installer method in the middle of that.

Dan, interesting concept.

I was actually thinking of separate folder and xml per product. And consolidating all that dev has for that product inside of one folder.

Say in example of Aerosoft, there is Ecosystem\Aerosoft and Effects. I created a separate folder for given airport, put everything in there, and added appropriately into xml. Seems to work fine.

I am still trying it out, seeing what the best concept is for me, but I thought this to be a good way to start it up, so I don't mix anything up.

Share this post


Link to post
1 hour ago, SimonC said:

Say in example of Aerosoft, there is Ecosystem\Aerosoft and Effects. I created a separate folder for given airport, put everything in there, and added appropriately into xml. Seems to work fine.

That works as long as:

1) You only copy textures, effects and sound into your declared XML directories that belong only to those airports.

2) There are no other Add-on's (Planes, Airports, etc.) that use the same Effect or texture names, that you are putting inside those folders.

Why?

When you declare Effects, Sounds or Textures inside of an XML and you use the Add'on's XML method you are instructing PDV4 to override any other effect, Sound or texture in the system with the ones declared on your folder structure.

To illustrate this, imagine this situation:

1) Plane A, it is a Boeing 737 under the sound subfolder there is a sound with the name EngineSound.WAV

2) Plane B, it is a Cessna and under the sound subfolder there is also a sound with the name EngineSound.WAV

Under normal circumstances both planes will load their own custom EngineSound.WAV since they are located under their own sound directory.

Now an end user decides that it doesn't want these planes under the normal SimObject directory, and it wants to copy their structure somewhere else, it copies each plane under D:\MyPlanes.

D:\MyPlanes\PlaneA

D:\MyPlanes\PlaneA\Sounds

D:\MyPlanes\PlaneA\Texture

D:\MyPlanes\PlaneA\Effects

Etc.

D:\MyPlanes\PlaneB

D:\MyPlanes\PlaneB\Sounds

D:\MyPlanes\PlaneB\Texture

D:\MyPlanes\PlaneA\Effects

Etc.

And for the sake of the example the user creates 2 XML  files, one for each plane.

Here is where people do mistakes, inside the XML they place entries for Effects, Texture and Sounds, this instruct PDV4 to override Sounds, Effects and Textures using filenames, what does this mean?, let me illustrate an example?

PDV4 reads your first XML, it says there is a Sound folder under D:\MyPlanes\PlaneA\Sounds

PDV4 reads your second XML, it says there is another Sound folder under D:\MyPlanes\PlaneB\Sounds

The last entry has priority over any sound folder in the system.

You open Prepard3D, it ask you to active the Add-on's and you said YES.

Next time you load the Cessna and the sim needs to locate the Sound EngineSound.WAV, the highest priority for this sound would be the sound located inside D:\MyPlanes\PlaneB\Sounds, which in this case is the right sound.

Now you load the Boeing, the sim needs to locate the Sound EngineSound.WAV, however the highest priority is still the sound located on D:\MyPlanes\PlaneB\Sounds, so unfortunatelly your 737 engine now sounds like a Cessna!. The same concept applies to Textures, Effects, Shaders, etc.

This is just an example of how many users are breaking their simulation environment due to the lack of understanding of the SDK Addon-on's XML method and behavior, I am not saying everybody does this mistake or that you would make this mistake, I am just raising awareness of the implications of the XML method, and before any user wants to start using it they should fully understand the consequences of what they are doing.

On the example above the correct method to move these planes is to copy the structure of the planes to the alternative directory and declare inside the XML only the SimObject directory (D:\MyPlanes), however a lot of users then find that some planes don't work under this scheme but this is because those planes need their developers to adapt their Gauges, Models, etc. to support the XML method in accordance with LM requirements.

Best Regards,

Simbol

 

Share this post


Link to post
13 minutes ago, simbol said:

PDV4 reads your first XML, it says there is a Sound folder under D:\MyPlanes\PlaneA\Sounds

PDV4 reads your second XML, it says there is another Sound folder under D:\MyPlanes\PlaneB\Sounds

The last entry has priority over any sound folder in the system.

Is this the case? I thought the Sound folder declared in the add-on.xml just gave P3D another sound folder to load files from. So, the PlaneA and PlaneB situation would only cause problems if they contained identical filenames?

I'll have to read through the SDK section properly! :blink:

Share this post


Link to post
1 minute ago, Ebs said:

Is this the case? I thought the Sound folder declared in the add-on.xml just gave P3D another sound folder to load files from. So, the PlaneA and PlaneB situation would only cause problems if they contained identical filenames?

I'll have to read through the SDK section properly! :blink:

How do you think my AI Lights are overriding all the default lights for all your planes without modifying any Aircraft.cfg file?

Best Regards

Simbol

Share this post


Link to post
18 minutes ago, simbol said:

PDV4 reads your first XML, it says there is a Sound folder under D:\MyPlanes\PlaneA\Sounds

PDV4 reads your second XML, it says there is another Sound folder under D:\MyPlanes\PlaneB\Sounds

The last entry has priority over any sound folder in the system.

Huh, that doesn't make a shred of sense. That would mean all and each addon developer must have unique filenames...?? :blink::blink: Or did I misunderstand something?

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now