September 20, 200916 yr hi everyone,is it possible to control the distance when library objects should appear. something like v1/v2?i have something here which i want to reduce the visibility to only 300m since this is a small object. but i don't know what term to usevis="300" or visible="300" or V1="300" or something else? and where to place it.i have sample line of the code. <SceneryObject lat="N14 31.1129" lon="E121 0.1991" alt="0" pitch="0" bank="0" heading="89" altitudeIsAgl="TRUE" imageComplexity="NORMAL"> <LibraryObject name="089DD7ED504A38501B021A8C6A10F5FF" scale="1.0"/></SceneryObject>thanks.
September 20, 200916 yr Commercial Member You can do that with LODs in Gmax before exporting the .mdl, or you might be able to do it with MDL Tweaker after the fact, but I don't think it's possible to do it in the placement xml. Are you building this object yourself in Gmax? Read the "house tutorial" section on LODs, it shouldn't be a problem although it'll probably require some experimenting to get the distance as you want it. It would help to know more about what you're trying to do exactly and why. At any rate your best bet for a solution is over at FsDeveloper.com, specifically the Scenery design forums.Best wishes,Jim
September 20, 200916 yr Author You can do that with LODs in Gmax before exporting the .mdl, or you might be able to do it with MDL Tweaker after the fact, but I don't think it's possible to do it in the placement xml. Are you building this object yourself in Gmax? Read the "house tutorial" section on LODs, it shouldn't be a problem although it'll probably require some experimenting to get the distance as you want it. It would help to know more about what you're trying to do exactly and why. At any rate your best bet for a solution is over at FsDeveloper.com, specifically the Scenery design forums.Best wishes,Jimhi jim,basically i am just adding extra objects to a scenery. these are rwy12 objects. there was one forum where somebody mentioned about adding some code to the property of an effect thereby controlling it's visibility range, but i could not find it anymore. i thought i could also try that with objects. major reason why i am doing this is i don't have the patience and the time to recreate these objects on my own; and to minimize the framerate hits. some of the objects are hidden behind buildings and are only visible once you go around it so it makes sense to have it "invisible" when it's not visible at all. or objects like trees where from a distance, i could only show several instances and they would only populate when you are very near.i could not find what i am looking for with the link you provided, although there are plenty of interesting stuff. thanks.
September 20, 200916 yr Commercial Member Yes there are some visibility conditions that can be used when placing effects (effectParams="NIGHT=1; DAY=0;" for example) but to my knowledge there's no similar way to control visibility of an object.I just tried it and it can definitely be done with MDL Tweaker though, although it's a somewhat involved process. Basically what you have to do is figure out which object library your .mdl is in, in this case it was "Static Objects Library\Scenery\ExtraObjects.BGL". Then you have to decompile that library with a tool like BglAnalyze. After decompiling you'll need to open ExtraObjects_23.mdl with MDL Tweaker and "Add object condition > New Condition > Distance to RefPoint" and set value "Max" to 300 (meters). Save the tweaked .mdl and compile it into a new object library/placement .bgl using a different GUID. Place the .bgl into your active scenery folder and copy the accompanying texture (car_dodge_van.bmp) from "Static Objects Library\Texture" into your active texture folder.Here's what I just came up with, I saved ExtraObjects_23.mdl as mini_van.mdl after tweaking with MDL Tweaker. You can put TEST_OBJECT.BGL into your RPLL scenery folder to check the new visibility condition but remove the old reference (in your first post) from the other .bgl first.RPLL_mini_van.zipMDL Tweaker can be found here:MDL Tweaker II 2.0.266 - Installer versionHope that helps,Jim
September 21, 200916 yr Author hi jim,thank you so much. this is actually the first time i understood the process. although i must say, i got lost on the part of recompiling all the tweaked mdl files back to bgl and assigning it a new GUID. correct me if i am wrong but the process of recompiling to bgl, based from what i read, is to create an xml file (similar to the one you sent) and in that assigning any value i can think of for GUID. then drop the xml file to bglcomp for conversion to bgl file? when i do this, there should only be one instance of xml and one instance of mdl file existing inside the bglcomp folder, else, it will not know which mdl file i am referring to? which brings me to another question if i may ask: each model or object i tweaked has to have a single xml file for recompiling or i can use one xml file for all mdl files? Place the .bgl into your active scenery folder and copy the accompanying texture (car_dodge_van.bmp) from "Static Objects Library\Texture" into your active texture folder.from what i understand is that you can only have one instance of the textures for runway 12 objects in your system else, all instance of an object in any scenery installed using the object would appear untextured (?).i must say i am impressed with your familiarity with the library objects. i never mentioned a vehicle and yet, based on the GUID code i gave, you sent me a sample of a car. : )lowil
September 22, 200916 yr Commercial Member Hi Lowil, sorry it took me so long to get back here.Yes, there are actually two ways of doing it. You can compile all of your .mdls into one "library object .bgl" and then use a separate placement .bgl to position the objects in the sim. This is the concept behind programs like Rwy12 and EZ Scenery (although I've never used either one). Another way is to combine the library objects and placement code into one .bgl which is what I did with the one I attached in the post above. If you open the .xml I included in Notepad you'll see the separate "<SceneryObject>" and "<ModelData>" portions of the code. To make a object library .bgl you'd just create an .xml containing only the "<ModelData>" something like this: <?xml version="1.0"?><FSData version="9.0"xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'xsi:noNamespaceSchemaLocation="bglcomp.xsd"><ModelData name="1f211aea2887700839fd5d619f4096fa" sourceFile="mini_van.mdl" fileOffset="0"/> <ModelData name="023fa07582264458873bbb43cac8d308" sourceFile="hangar_five.mdl" fileOffset="0"/> <ModelData name="72afd8ef766387245c2c4cefae7c76f1" sourceFile="pole_light.mdl" fileOffset="0"/> <ModelData name="4606f05b2a7e580b1107a797564074c5" sourceFile="red_barn.mdl" fileOffset="0"/> <ModelData name="262eacb694460a5e39413197ef50d6f2" sourceFile="farmhouse.mdl" fileOffset="0"/></FSData> You'd just save the above as something like "object_library.xml" and when you drop the file onto bglcomp.exe it will compile an "object_library.bgl" in the same folder providing "mini_van.mdl", hangar_five.mdl, pole_light.mdl, etc were in the folder as well. These .mdls will be compiled right into the .bgl which you can then drop into an active scenery folder such as "Static Objects Library\Scenery" where they can be called up for use in the sim by an object placement .bgl located in any active scenery folder.GUIDs are automatically generated in a sample .xml when you export a .mdl from Gmax so I generally just use that GUID for anything that has to do with that particular object. It's considered a bad practice to have more than one instance of the same GUID anywhere in your FS installation so that's why I changed it. You can probably get away with just changing the GUID manually if necessary as in this case with the tweaked .mdl, but it has to remain a 32 character alphanumeric string so be careful. When I need to generate a new random GUID I use a checksum verification utility to get the MD5 "hash" of some random file and use that. There's a handy freeware utility you can download called digestIT 2004, google it. With digestIT 2004 installed you can right click on any file and select "Calculate MD5 Hash" and it will generate a perfect 32 character alphanumeric string that you can use as a GUID.Regarding textures, the only problem I see with duplicate copies would be if you had a copy of "car_dodge_van.bmp" in your main Flight Simulator 9\Texture folder. As long as you don't have it there (or possibly your Addon Scenery\Texture folder) you won't have problems with duplicates in any other texture folder. In fact, if you place TEST_OBJECT.bgl into an active scenery folder and you don't have a copy of "car_dodge_van.bmp" in it's accompanying texture folder, the mini van will show up untextured in the sim. "i must say i am impressed with your familiarity with the library objects. i never mentioned a vehicle and yet, based on the GUID code i gave, you sent me a sample of a car."I just copied your code to an .xml and compiled it on the odd chance that it was an object that I had installed. I went to the location and low & behold there was a minivan sitting there. I recognized it as a rwy12 object and it just happens that I was checking out the sample placement of those cars at Victoria BC the other day so I knew just which .bgl to decompile. :(Hope that sheds some light, as I mentioned earlier, check out FSDeveloper and get friendly with the search button if you really want to master the art of FS scenery.Jim
September 22, 200916 yr Author hi jim,thank you so much. you have been most patient with me. you're a genius, man! ... as I mentioned earlier, check out FSDeveloper and get friendly with the search button if you really want to master the art of FS scenery.and yes, i will take your advice.best,lowil
Create an account or sign in to comment