CreateAGNPolyBuild with multiple GUIDs

#1
Hi,

I'm trying put multiple GUIDs in a specific area, but the P3D render only the last guid.

Code:
CreateAGNGenBuild|ROOFTYPE="HOUSE001"|{ab8d70b7-7693-4a39-9b52-1f8c8fa32b47};{c9f2e68f-ba5a-4fd0-8d1d-7e88f6765c5c}
CreateAGNGenBuild|ROOFTYPE="HOUSE002"|ab8d70b7-7693-4a39-9b52-1f8c8fa32b47;c9f2e68f-ba5a-4fd0-8d1d-7e88f6765c5c
What am I missing or doing wrong?

TY!
 

arno

Administrator
Staff member
FSDevConf team
Resource contributor
#2
It should randomly pick a GUID in this case. For each feature that matches your filter.
 
#3
So scenProc apply one of these (randomly) GUIDs in my filter (all polygons), it's possible use the GUIDs randomly for each polygon?

TY arno!
 
Last edited:

arno

Administrator
Staff member
FSDevConf team
Resource contributor
#4
scenProc will already randomly select a GUID from the list for each polygon. So in your case you should end up with a mixture of the two roof guids.

If you check the generated agn files with Annotator or agn2txt you don't see that?
 
#7
Hi Guys,

I run a little test again today, with these lines:
Code:
ImportOGR|shape\buildings.shp|*|*|NOREPROJ
ImportOGR|shape\landuse.shp|*|*|NOREPROJ

SplitGrid|AGN|*|building="*"

AddAttributeIfInside|FTYPE="POLYGON" AND building="*"|LUCODE=100|String;BUILDCAT|HOUSE001
AddAttribute|BUILDCAT="HOUSE001"|String;ROOFTYPE|HOUSE001

CreateAGNGenBuild|ROOFTYPE="HOUSE001"|{571c6e87-7e22-4aaf-ba41-769323e3bf0e};{eb33e6d6-a1b5-4e27-99c6-9d4c21e58f55}

EXPORTAGN|FSX|D:\Lockheed Martin\Prepar3D v4\FLYT\TESTE\texture
Result:
Code:
18:29    ExportAGN    Information    Created 1896 generic buildings objects
18:29    ExportAGN    Information    Written 5 autogen files
Then, i checked each autogen file with agn2txt, all of them result one GUID:
571c6e87-7e22-4aaf-ba41-769323e3bf0e

agn2txt (small part):
Code:
Location 030200301112201
Variant -1
GenericBuildingTexture Default
RowHouseTexture Default
BuildingHeights 1 0 0 0
VegetationClasses 0 0
VegetationDensity 0 0
VegetationHeights 0 0 0 0
AGNGenericBuilding {571c6e87-7e22-4aaf-ba41-769323e3bf0e} 0.48465633392334 0.207556247711182 0.526135921478271 -0.850400447845459 0.0238041877746582 0.0137190818786621
AGNGenericBuilding {571c6e87-7e22-4aaf-ba41-769323e3bf0e} 0.499490261077881 0.220236778259277 -0.526288986206055 0.850305557250977 0.0139026641845703 0.0166130065917969
AGNGenericBuilding {571c6e87-7e22-4aaf-ba41-769323e3bf0e} 0.475888729095459 0.220804691314697 0.850180625915527 0.526490688323975 0.0215568542480469 0.0124821662902832
AGNGenericBuilding {571c6e87-7e22-4aaf-ba41-769323e3bf0e} 0.468479156494141 0.150856018066406 0.587403297424316 -0.8092942237854 0.0164947509765625 0.021909236907959
AGNGenericBuilding {571c6e87-7e22-4aaf-ba41-769323e3bf0e} 0.457851886749268 0.204158782958984 0.850042343139648 0.526713848114014 0.00752019882202148 0.0063633918762207
AGNGenericBuilding {571c6e87-7e22-4aaf-ba41-769323e3bf0e} 0.46217155456543 0.192012310028076 -0.526638984680176 0.850089073181152 0.0119824409484863 0.00616359710693359
AGNGenericBuilding {571c6e87-7e22-4aaf-ba41-769323e3bf0e} 0.44778299331665 0.183631420135498 0.526088237762451 -0.850430011749268 0.0232176780700684 0.0153160095214844
AGNGenericBuilding {571c6e87-7e22-4aaf-ba41-769323e3bf0e} 0.466384887695313 0.183982849121094 0.849755764007568 0.527175903320313 0.00429201126098633 0.00331354141235352
AGNGenericBuilding {571c6e87-7e22-4aaf-ba41-769323e3bf0e} 0.478138446807861 0.182363033294678 -0.526173114776611 0.850377082824707 0.00827693939208984 0.00552940368652344
AGNGenericBuilding {571c6e87-7e22-4aaf-ba41-769323e3bf0e} 0.487498760223389 0.164590358734131 -0.526409149169922 0.850231647491455 0.00954580307006836 0.00452852249145508
AGNGenericBuilding {571c6e87-7e22-4aaf-ba41-769323e3bf0e} 0.465758800506592 0.149820804595947 0.85020923614502 0.526444435119629 0.0178408622741699 0.013031005859375
AGNGenericBuilding {571c6e87-7e22-4aaf-ba41-769323e3bf0e} 0.452967643737793 0.163134098052979 0.526914596557617 -0.849918365478516 0.00619363784790039 0.00504636764526367
AGNGenericBuilding {571c6e87-7e22-4aaf-ba41-769323e3bf0e} 0.456116199493408 0.157722949981689 -0.526670932769775 0.850069046020508 0.00729846954345703 0.00590944290161133
AGNGenericBuilding {571c6e87-7e22-4aaf-ba41-769323e3bf0e} 0.505087852478027 0.0601353645324707 -0.526096343994141 0.850424766540527 0.0137100219726563 0.00649881362915039
AGNGenericBuilding {571c6e87-7e22-4aaf-ba41-769323e3bf0e} 0.495390892028809 0.117551803588867 -0.850318908691406 -0.526268482208252 0.0138359069824219 0.0118460655212402
AGNGenericBuilding {571c6e87-7e22-4aaf-ba41-769323e3bf0e} 0.475787162780762 0.104920864105225 0.850345611572266 0.526224136352539 0.0230026245117188 0.0194964408874512
Testing with P3D v4.4:
Sem Título-1.png


I'm using scenProc v2.0.0.0 r1a8f7e68 DEV 29/11/2018.
Any ideas?

TY!
 

arno

Administrator
Staff member
FSDevConf team
Resource contributor
#8
OK, I'll try to reproduce it here. Sounds like you found a bug to me.
 

arno

Administrator
Staff member
FSDevConf team
Resource contributor
#10
Hi,

You found a bug indeed. I checked the code and there was a mistake in there that caused the last GUID never to be selected. It will be fixed in the next development release.
 
#11
Nice arno, thank you!

For now, can i use the last GUID twice? To force render of two GUIDs, ex:
Code:
CreateAGNGenBuild|ROOFTYPE="HOUSE001"|{571c6e87-7e22-4aaf-ba41-769323e3bf0e};{eb33e6d6-a1b5-4e27-99c6-9d4c21e58f55};{eb33e6d6-a1b5-4e27-99c6-9d4c21e58f55}
 

arno

Administrator
Staff member
FSDevConf team
Resource contributor
#12
Yes you could do that. But the new build is online already as well.
 
Top