Something is wrong with how P3D reads my addon xml entries

Any issues, problems or troubleshooting topics related to the Prepar3D client application.
Senchay
Posts: 98
Joined: Wed Jun 07, 2017 4:47 pm

Something is wrong with how P3D reads my addon xml entries

Postby Senchay » Fri Feb 15, 2019 3:14 am

Hello.

I have a really weird issue... Somehow P3D reads the order of my addon.xml wrong. Where is this order even written down? As you can see here ZUUU, not an addon.xml entry comes at the first position. In the scenery.cfg this has the entry nr 248.

Image

But that is not the only problem. The whole order is not as it should be. Before i installed WSSS it was like this (just think WSSS out of the pic. The order was exactly like this, without WSSS)

Image

Right after install of WSSS it went to this

Image

You can see that the Flytampa entries are not there. They follow way down somewhere.

So i went on to find out why and i guess the reason is that those Flytampa entries are in an other folder as all others...

So we have one addoncfg in the folder ProgramFiles and one in the %appdata%/Lockheed Martin/P3d v4 folder. The Flytampa ones are in one and the rest somewhere else.

How can this happen and wich one is the right one. The one in Programfiles has all others and the one in %appdata% only 3 from Flytampa.

But anyway, why does ZUUU shows at pos 1 when it is a scenery.cfg entry at pos 248?

I dont get it anymore...

This everytime results in a broken simstate where many things dont work as they should anymore. But that would be too long to write down...
P3D 4.4, I7700K, 2080 RTX, 16GB Ram, Asus Prime Z270K, Win 10

Senchay
Posts: 98
Joined: Wed Jun 07, 2017 4:47 pm

Re: Something is wrong with how P3D reads my addon xml entries

Postby Senchay » Fri Feb 15, 2019 11:48 am

Forgot to add something.

This state also means i get a ctd when im i try to change certain settings related to scenery. Like when i change scenery density, click ok it will ctd.

This always happens after i see this order changed.
P3D 4.4, I7700K, 2080 RTX, 16GB Ram, Asus Prime Z270K, Win 10

Martyson
Posts: 5879
Joined: Sun Mar 25, 2012 11:08 am

Re: Something is wrong with how P3D reads my addon xml entries

Postby Martyson » Fri Feb 15, 2019 12:22 pm

I cannot read the text in your screenshots.

What is the content of your xml file?
Best Regards,
Vaughan Martell (KDTW)

User avatar
WarpD
Posts: 1446
Joined: Mon Feb 14, 2011 5:29 am

Re: Something is wrong with how P3D reads my addon xml entries

Postby WarpD » Fri Feb 15, 2019 12:44 pm

Using a 3rd party application to control the content of the file means you should be talking to the developer of the third party app.
Ed Wilson
Senior Developer
Mindstar Aviation

User avatar
downscc
Posts: 1397
Joined: Mon Dec 01, 2014 5:46 pm
Location: KCRP

Re: Something is wrong with how P3D reads my addon xml entries

Postby downscc » Fri Feb 15, 2019 4:50 pm

Agree with Ed.

The entries in the scenery.cfg will be 'lower' on the library list than those using an add-on.xml, and the order of add-on.xml entries using the self discovery method (the add-on.xml is in a documents add-on folder) will be in the order read such that last read (last subfolder and last component in the add-on.xml) will be 'on top.'

Add-on.xml components using an add-on.cfg entry in the program data folder (the recommended method for developers) will be added 'above' scenery.cfg and 'below' the self discovery items I think.... regardless, this order only has meaning for a few specific kinds of add-ons and those have their own properties to deal with this.
Dan Downs
KCRP

Senchay
Posts: 98
Joined: Wed Jun 07, 2017 4:47 pm

Re: Something is wrong with how P3D reads my addon xml entries

Postby Senchay » Fri Feb 15, 2019 5:41 pm

Using a 3rd party application to control the content of the file means you should be talking to the developer of the third party app.
Yes, probably. But this doesnt have to do with Simstarter. It happens exactly the same in P3D only usage. I just used that pic because that was the only place that showed the "old" order. I had my chat with the dev already.
The entries in the scenery.cfg will be 'lower' on the library list than those using an add-on.xml, and the order of add-on.xml entries using the self discovery method (the add-on.xml is in a documents add-on folder) will be in the order read such that last read (last subfolder and last component in the add-on.xml) will be 'on top.'
Thank you so far. But as you can see is ZUUU at the top, despite it being a scenery.cfg entry. And nothing i do can change this. When i load the sim ZUUU is places ontop, as well as other scenery.cfg entries here and there inbetween.

If i open my scenery.cfg it shows the 2 layers ZUUU has, terrain and scenery at pos 246 and 247.

Also, i know that the order is only relevant so far as the scenery has to be above terrain (in most but very few cases DigitalDesign EDDP where its opposite. And that ORBX stuff between airports and between standard scenery/terrain layers.

Its not that im really unfamiliar with all this, doing support in our community i came across alot of things that i usually can fix.

But this all is so weird. I would not care about the order if this "broken" state would not cause other issues. Big issues. The mesh doesnt load as it should, autogen is way slower and here and there standard scenery is overlapping thirsparty addons, despite all is in the right place.

So i have the feeling that something else happens in the background, not visible in the order itself. Also FPS is way worse in this state and like mentioned, a change in terrain settings end in a ctd in 90% of cases.

Whenever im able to fix this again my sim is one of the best running i came across one. Where other (just an example) rant about London fps in the single digits i fly there in a pmdg 748 with 40 fps in the vc and 80 to 100 outside view. While every inch of terrain is super crisp.

All this glory is gone when this happens and my sim is one of the many blurry, low autogen and low fos sims.

Please believe me that when i say this i compare ALWAYS in same weather, at exact same time in the exact same plane on the exact same route.

The following pics should only be seen as an example... in no way i want to brag about my pc or sim...

Over London (over 90 fps) outside

Image

VC (45 - 50 fps)

EGLL (45-50 FPS)
Image

Image

Dyn Lights, many of them (over 40 fps in vc)

Image

KPDX departure with SSAA and 4k textures and the ORBX region (PNW?) its in (41 fps in vc)

Image

Alps mesh/elevation, all looks nice as it should

Image


Now sadly i dont have comparison pics from bad state but fps are around 15 to 20 lower as seen here in the broken state, everywhere. Mesh/Elevation looks very bland and not detailed really and autogen loads very late. And just to have it al together, like mentioned - it ctd when changing terrain settings and some standard buildings are placed in the middle of payware airports.

I dont use FSX sceneries, only v4, i dont install all kind of stuff, i dont do custom things to my addon.xml file i dont do anything at all basically that i think would harm my sim in any way. I really try to be careful here but this problem just always seem to appear after installing lots of scenery.
P3D 4.4, I7700K, 2080 RTX, 16GB Ram, Asus Prime Z270K, Win 10

Senchay
Posts: 98
Joined: Wed Jun 07, 2017 4:47 pm

Re: Something is wrong with how P3D reads my addon xml entries

Postby Senchay » Mon Feb 18, 2019 7:16 pm

Now to bring more sense into the above pics...

This is my sim now in this weird state

Mega blurry (current state)
Image



Terrain before. I could go mach 1 and no blurries, nothing. No autogen lost. All fluid into the 100 fps. And it does not matter how long i do this.
Image

Image

Terrain now

Absolutley no elevation detail in an area where i usually have it. Very low fps (below 30 always and everywhere, where i usually have 40+ in full overcast. Now i cannot reach same on clear sky.

Image

What i noticed also is that in this state my GPU seems nearly idling. It runs then on a very low core freq of around 300 to 800 mhz and below 25% load, sometimes it may go to 1100mhz and 35% load. Usually i always see it maxed with at least 40 to 70% load. Im just at a full loss. As if something doesnt arrive the gpu. I never saw it idling so much.

I can see already that a new install awaits again, every year the same for 2 or 3 times... I really hope the day will come where this doesnt need to be done anymore.

Also notice here... whenever i order an item of the scenery.cfg entries it swaps the order of xml entries...

This is the state when i open sim and go into library

Image

When i now scroll down where the scenery entries are and move one airport, doesnt matter wich one, one place up or down everything in the xml section swaps to this

Image

When i press ok now i get an error from p3d, something with scenery order wrong (non sequential layer ordering). This is when i do it in this menu. When i press ok in the library while in a scenery i get a ctd of kernelbase.dll...


What you think, what makes most sense in such state... is a "delete generated files" enough? or should i reinstall everything.... Im near to give up on this thing really. Every year the same story. Yes, i had this multiple times already since i started with p3d. It always happens at one point, over night basically.
P3D 4.4, I7700K, 2080 RTX, 16GB Ram, Asus Prime Z270K, Win 10

jabloomf1230
Posts: 235
Joined: Thu Nov 01, 2012 7:40 pm

Re: Something is wrong with how P3D reads my addon xml entries

Postby jabloomf1230 » Tue Feb 19, 2019 8:09 pm

Here's what I suggest. Download the freeware editor Notepad++. Notepad++ has a feature "search in files" that allows one to search for a string in all the files in an entire folder, including subfolders. One would want to search in the folder:

Documents\Prepar3D v4 Add-ons

(and any other folders that have add-on.xml files, according to the contents of the two copies of add-ons.cfg)

for the string:

<LAYER>

with a file template of:

add-on.xml

Now open up a copy of your scenery.cfg and make sure that all the layers are consecutive and present. Note the number of the last layer, which is usually the highest numerically in scenery.cfg and hence the highest priority entry in your scenery library (except for the add-on.xml scenery items). Make sure that all the <LAYER> statements in your add-on.xml files are bigger numbers than the largest layer number in scenery.cfg. Also make sure that no layer numbers are duplicated. It's not documented in the SDK that one can't have lower numbered layers in add-on.xml files than what is found in scenery.cfg, but it just seems like a bad idea to do so in your case. Note that most add-on.xml files do not contain a <LAYER> entry and the sim layers them as new add-on.xml files are encountered.

Next, go to the hidden folder:

C:\ProgramData\Lockheed Martin\Prepar3D v4\SceneryIndexes_x64

and delete all the *.dat files in this folder. This will force P3d4 to recreate its scenery index when you next run the sim. In the sim, now check your add-ons/scenery library in P3d4 and see what it looks like.

Senchay
Posts: 98
Joined: Wed Jun 07, 2017 4:47 pm

Re: Something is wrong with how P3D reads my addon xml entries

Postby Senchay » Wed Feb 20, 2019 2:57 pm

Thanks a lot so far, i will look into this. That SceneryIndexes_x64 thing sounds interesting, i will try that next time. And im sure next time will come...

The "scenery_add-ons.xml" would have been my next question, i saw that there are also numbers in it that i cannot understand what they are for. What is the

<SceneryCRC>-1586901003</SceneryCRC>

and where does it come from? And how does it relate to the other files? Anyway is there anywhere a place where i can read how this all works? Seems rather complicated to have 4 or more different places where scenery entries are somehow related.

We have SceneryStatus.bin that seems to relate directly to this scenery_add-ons.xml, i see always same timestamp of those 2 in "last changes" row in explorer.

Then we have the one add-ons.cfg in %appdata% that from the 150 airports i have only FLytampa seem to use. Then we have Prepar3D v4 Add-ons folder that is selfdetected. Then we have the add-ons.cfg in C:\ProgramData\Lockheed Martin\Prepar3D v4... seems this is the favourite of devs, this is where probably 50% of my airports reside. Then we have the scenery.cfg.... Then we have OldScenery.cfg. probably just a backup.

Now @downscc already explained a part (thanks again), still many questions still left to answer.

Btw, im sorry for m probably angry tone but this is just sooooooo time consuming that sometimes im really angry... doesnt help noone i know. Dont think im not thankful for the answers so far, thats not how it is. But if one spends dozens of hours to try to fix something then i think everyone is at this point at some point...

@Martyson i think if you rightclick the pick and tell it to "open in new tab" you can see the pic in original form/size.

Now the good thing...

Seems it magically fixed itself now again after i did the above things (what ive mentioned in last post) a few times in row. At one point the error didnt come up anymore and all is good again... fps are back, blurries gone. No ctd when changing the terrain settings.

LM please do us all one favour and LET GO OF OLD THINGS with at least p3d 5.... FSX users should not be our concern in the year 2019. I understand very well that ppl spent lots of money for old scenery but its just too late now to always have backwards compatibility for this group. I will loose same money but i bet it would make P3d so much better if really one can focus on new tech instead of always going 1 step ahead and 2 back because of this reason.

Sooo many ppl are flying around with a broken sim. One just has to take a look to the streamers, many sims dont work as they should. Ppl have blurries and no autogen and im nearly sure it all relates to this reason of a broken scenery. Sure, if one fills his sim with 591 addons there will be the point where everything is too late and others use it wrong but there is still a big number of ppl who do everything right, with brain too and still have this outcome at one point. This is bad.

If one knows how p3d really can run its such a shame to see how ppl rant about it everywhere because they think the blurries and low fps is a normal thing. Its NOT. Its the outcome if installing things into his sim. In the right way... Thats the problem
P3D 4.4, I7700K, 2080 RTX, 16GB Ram, Asus Prime Z270K, Win 10

User avatar
downscc
Posts: 1397
Joined: Mon Dec 01, 2014 5:46 pm
Location: KCRP

Re: Something is wrong with how P3D reads my addon xml entries

Postby downscc » Wed Feb 20, 2019 5:13 pm

The scenery_add-ons.xml is not a user file. I suspect P3D uses this file to keep track of what add-ons are the same as last session and what has changed.

<SceneryCRC>-1586901003</SceneryCRC>

The CRC is simply a kind of hash code that is used to define an instance of an add-on set of files. If any of the add-on files are changed, such as a minor edit to an AFCAD, it will result in a different CRC sum and P3D will then know that this add-on is revised.

The documentation of how the add-on.xml and add-on.cfg files should be used is provided in detail in the SDK. I spent a few hours studying this and playing with different things learning how to take advantage of what this scheme can provide. It's not hard...just takes a little bit of time and effort. I recommend this reading to anyone interested in learning how add-ons work. For those without the time or motivation I recommend Lorby's Addon Organizer, which takes care of this stuff for you.
Dan Downs
KCRP

Senchay
Posts: 98
Joined: Wed Jun 07, 2017 4:47 pm

Re: Something is wrong with how P3D reads my addon xml entries

Postby Senchay » Thu Feb 21, 2019 3:45 pm

Thank you @downscc :-)
P3D 4.4, I7700K, 2080 RTX, 16GB Ram, Asus Prime Z270K, Win 10

Senchay
Posts: 98
Joined: Wed Jun 07, 2017 4:47 pm

Re: Something is wrong with how P3D reads my addon xml entries

Postby Senchay » Thu Mar 07, 2019 12:47 am

Now i have another question.

Guess this shows i have some problem, right.

Why anyway is the scenerycfg entry from Singapore inbetween the addon xml entries?

And watch this video please, i cant move them below. That vid is not on repeat, i try this during that whole vid multiple times. You see even another one (ZUUU) is coming up out of nowhere.

https://youtu.be/gK90W1QU1f8
P3D 4.4, I7700K, 2080 RTX, 16GB Ram, Asus Prime Z270K, Win 10

Senchay
Posts: 98
Joined: Wed Jun 07, 2017 4:47 pm

Re: Something is wrong with how P3D reads my addon xml entries

Postby Senchay » Sat Mar 09, 2019 2:35 am

Guess this has something to do with it, can it be...

https://www.avsim.com/forums/topic/5497 ... ry-broken/
P3D 4.4, I7700K, 2080 RTX, 16GB Ram, Asus Prime Z270K, Win 10

Senchay
Posts: 98
Joined: Wed Jun 07, 2017 4:47 pm

Re: Something is wrong with how P3D reads my addon xml entries

Postby Senchay » Sat Mar 09, 2019 4:04 am

And i found how to fix it.

Now someone from LM really should read this....I feel like talking to myself.

This seems to be clearly a P3d thing. If not then please reply so i can let the dev know about it. Maybe it has to do with WSSS having 4 layers or whatever, i dont know. But this is the way i can fix it so both, Simstarter and P3D are showing the same thing. And where WSSS doesnt overlap with standard scenery.

The file add-ons.cfg in

C:\ProgramData\Lockheed Martin\Prepar3D v4

When one is installing WSSS, at least in my case it will be added as

[Package.0]
PATH=E:\P3D\Addon Scenery\ImagineSim\WSSS Singapore P3Dv4
TITLE=Imagine Simulation WSSS2_PD4
ACTIVE=true
REQUIRED=false

The next entry for me is

[Package.1]
PATH=E:\P3D\Ecosystem\Aerosoft\Aerosoft-Maastricht
TITLE=Aerosoft-Maastricht
ACTIVE=false
REQUIRED=false

and this continues up to

[Package.51]
PATH=C:\Users\Alex Wolff\Documents\Prepar3D v4 Add-ons\UUEE Moscow Sheremetyevo X
ACTIVE=true
REQUIRED=false

Now, if one looks here

Image

one can see that UUEE is the very first shown here on top. That one has the number 51 in that file. So i wondered why WSSS is Nr 0 BUT also stays ontop after first install, at least for a short time. Maybe 1 simstart or until another addon xml scenery is installed.

Then it gets split up to something like this

Image

Where 2 of the 4 layers stay at top and the other 2 end up at the bottom of all addon xml entries.

What i did now is ordering the numbers so WSSS is entry

[Package.52]
PATH=E:\P3D\Addon Scenery\ImagineSim\WSSS Singapore P3Dv4
TITLE=Imagine Simulation WSSS2_PD4
ACTIVE=true
REQUIRED=false

instead of 0 .

So now WSSS is nr 52 (the very last one) and UUEE has this

[Package.51]
PATH=C:\Users\Alex Wolff\Documents\Prepar3D v4 Add-ons\UUEE Moscow Sheremetyevo X
ACTIVE=true
REQUIRED=false

Now WSSS stays at pos 1, with all 4 layers together how they belong

Image

The same is reflected by Simstarter now too

Image

As soon WSSS is Nr 0 again it gets split up in 2 parts, causing problems for seemingly the whole sim. I tried it. Putting it back to the last numbers fixes it again.

What i ALSO had to do is to delete all Flytampa entries out of

C:\Users\sdsdsd\AppData\Roaming\Lockheed Martin\Prepar3D v4

Flytampa chose to add their entries there for whatever reason. And i saw that also causes problems in 4.4. So i deleted them. P3D would put those ones after the rest of addon xml entries while simstarter puts them ontop.

Something is clearly wrong how 4.4 handles the order of entries, as can be seen here.

https://www.avsim.com/forums/topic/5497 ... ry-broken/

Now please someone respond to let ppl fix this if its not a P3D problem. I dont care anymore who is "at fault" but i know that i wasted probably over 20h to get into the root of this. Its not my job, every developer seems to put the fault to someone else or doesnt even respond at all. Thats so bad...

Again put together:

If my scenery library consists of the addon.cfg from %appdata% AND the addon cfg from %program data% AND scenery cfg entries i CANNOT fix this at all because then the ordering is fully broken and weird things happen. Maybe this happens only with lots of scenery i dont know anymore... But its like that.

If i only have the entries in the addon cfg in %program data% and scenery cfg entries i can fix it by putting the last installed WSSS as the last position in the addon cfg (nr 52 in my case), instead at nr 0 where it will be installed.

I hope i could make it clear. English isnt my native language.
P3D 4.4, I7700K, 2080 RTX, 16GB Ram, Asus Prime Z270K, Win 10

shfinne04
Posts: 4
Joined: Fri Dec 12, 2014 9:39 pm

Re: Something is wrong with how P3D reads my addon xml entries

Postby shfinne04 » Wed Mar 20, 2019 1:29 am

Right now do i have about 1Tb off add-on in total mess
under grown landings. (tffj) stips floting.(tffs) guess FlyTampa mesh (locked) EOL Below all high res mesh
airport in holes (tap)????? and lot of missing parts of scenery's (lhbp lime) not sure what add on in TOL kill*s of airport structure ESSA was filled with tree and houses Can be that was a obrx thing mostly fix in last ver. not checked all after this fault started But so far try fixing have just made thing .. basically F......P all All Germ and Nor work

but 17GB in my document folder was a not a nice discovery LOL

Im not sure if this is a problem made by developer's or Prepar3d
but think it has to be looked at
it is a Nightmare for big installations
Where you need to have CONTROL


Im now going to make a reinstall
all under a separate user with folder set to a separate SSD and Program structure a separate SSD
I guess i need to read all addon.xml
NO abosulute NO Scenery's will be add on's all manual installed

If this was made really good the P3d shoude be able to run from different users then installed under
so no users get any write permits to any of the setup files.

All personal prefs in users structure, documents

All file that a common that need to have write permits goes into user\public\prepar3D
This will make it more or less secure and safe.
Like it work to day running a lot of program's as administrator is madness

The structure thing takes now is more suited for a GAME.. LOL

Styrk H Finne


Return to “Prepar3D Client Application Questions”

Who is online

Users browsing this forum: Google [Bot] and 11 guests