• Which the release of FS2020 we see an explosition of activity on the forun and of course we are very happy to see this. But having all questions about FS2020 in one forum becomes a bit messy. So therefore we would like to ask you all to use the following guidelines when posting your questions:

    • Tag FS2020 specific questions with the MSFS2020 tag.
    • Questions about making 3D assets can be posted in the 3D asset design forum. Either post them in the subforum of the modelling tool you use or in the general forum if they are general.
    • Questions about aircraft design can be posted in the Aircraft design forum
    • Questions about airport design can be posted in the FS2020 airport design forum. Once airport development tools have been updated for FS2020 you can post tool speciifc questions in the subforums of those tools as well of course.
    • Questions about terrain design can be posted in the FS2020 terrain design forum.
    • Questions about SimConnect can be posted in the SimConnect forum.

    Any other question that is not specific to an aspect of development or tool can be posted in the General chat forum.

    By following these guidelines we make sure that the forums remain easy to read for everybody and also that the right people can find your post to answer it.

FSX Locating BGL file for a specific airport

Messages
1,564
Country
thailand
I would like to know how to identify the bgl file associated with a specific airport, for example, KIAH, which I would then like to view using BglAnalyzeX.exe.

I think that will get me where I want to go ... My ultimate goal is to simply identify which variable in the airport scenery file contains the lat/lon of the tower view that FSX uses when it places the tower in a Multiplayer Air Traffic Controller session. I am particularly curious about tower views at airports having more than one tower object, such as KIAH, and what that looks like in terms of the bgl file.

Anyway, apologies for asking a basic question that is no doubt already addressed some where in here, but i cannot find it. And as you probably guess, I am brand new to scenery design, so I hope I can make some sense of the bgl.

Thanks for you help in advance!

Bob
 
It is determined differently for FS9 and FSX. I see you want to use BglAnalyzeX to decompile the Bgl file so I guess it is FX. I can save you a bit of work though since there is a data file in ADE called airportList.dat that contains all the stock airports. Apart from information about the name, location etc it contains the Bgl file holding the airport. There is one of these for FS9, FSX and P3D and I have no problem if you would like to use them.

As far as tower viewpoints are concerned there is only one per airport. Some airports have multiple tower objects and that is a different thing.

You need to be aware that the tower viewpoint is a separate item from the tower objects. In FSX a change in the XML allowed objects to be associated directly with the tower viewpoint. This can create some complications so ADE (for example) converts any objects attached to the tower viewpoint to separate objects.

However if you are just trying to get the coordinates of the tower viewpoint for an airport then that is actually quite simple. I could probably generate a list of all airports and tower viewpoint coords from the ADE scanners given a few days. Doing it file by file and airport by airport using a generic decompiler will take a while!
 
Thanks Jon,

I just wanted to look at a bgl file and see how the tower view was defined .. by which variable.

I am completing my fs9gps:Map guidebook (companion the the FS9GPS Module guidebook) and I'm chasing down a detail related to range rings. In a multiplayer Controller session A:pLANE LATITUDE and LONGITUDE, and hence, the range rings, are centered on the tower view. But, tower view is not a gps database variable, so I guessed it was to be found in the bgl file only. That's my interest in the bgl file ... which variable is the tower view? This is of course a FSX question because it has to do with range rings.

I'm aware by reading though the ADE manual and simply by looking at Controller sessions that there can be multiple tower objects, but only one tower view.

Frankly, to keep it very very simple, all I really need is the name of any bgl airport file ... preferably one that has more than one tower object. Or, just the decompiled XML of it.

Make sense?

Thanks for the help,

Bob
 
I can't say which airport has multiple tower objects. However the airportList file mentioned above will tell you which airport is in which file. The file is separated values - the separator is | So you could load it into a spreadsheet and use that to search and sort the data.
 
I can't say which airport has multiple tower objects. However the airportList file mentioned above will tell you which airport is in which file. The file is separated values - the separator is | So you could load it into a spreadsheet and use that to search and sort the data.

Perfect. Many thanks.

Bob
 
AFAIK, you can have only one tower view in an airport. However, I assume he meant a BGL file with more than one tower in it (at more than one airport, one tower each).

Any of the AP or APX files in the default scenery is what you are looking for - they contain the airport information.

Hope this helps,
 
Last edited:
I would like to know how to identify the bgl file associated with a specific airport, for example, KIAH, which I would then like to view using BglAnalyzeX.exe.

I think that will get me where I want to go ... My ultimate goal is to simply identify which variable in the airport scenery file contains the lat/lon of the tower view that FSX uses when it places the tower in a Multiplayer Air Traffic Controller session. I am particularly curious about tower views at airports having more than one tower object, such as KIAH, and what that looks like in terms of the bgl file.

Anyway, apologies for asking a basic question that is no doubt already addressed some where in here, but i cannot find it. And as you probably guess, I am brand new to scenery design, so I hope I can make some sense of the bgl.

Thanks for you help in advance!

Bob


Bob

You do not need to decompile any airport bgl to study the tower position in a Multiplayer Air Traffic Controller session.

All airports have a Tower Viewpoint. In some cases there is a actual tower sceneryobject at this lat/lon location. Many small GA airports do not have a actual tower but the Tower Viewpoint is still a lat/lon in the bgl.

Using ADE open any stock airport such as KIAH and find the circle with a T. This is the Tower Viewpoint with or without a tower.

When you start a Multiplayer Air Traffic Controller session it will place the tower at the viewpoint lat/lon. Only one Tower Viewpoint per airport can be in the airport bgl.

Here is an example using ADE that shows the tower viewpoint and its porperty. The Multiplayer Air Traffic Controller Tower will be placed at the viewpoint.


 
Thanks, everyone!

My goal was to find the lat lon variables that FSX uses for the tower view in a multiplayer Controller session because I wanted to determine the variables it reads to place A:pLANE LATITUDE and LONGITUDE which define the center of RangeRings. Because Tower View lat and lon are not gps variables, I knew I needed to look at the airport scenery file.

Following Jon's suggestion to find the bgl file name in airportList.dat, I took a look at KIAH and several other airports having multiple tower objects so I could differentiate the tower view from other tower objects. The tower view is defined by the lat lon of the <SceneryObject> within <Tower>, and that's what I was after.

Regards,

Bob
 
Hi,

You can also find that information in the BglComp SDK:

Tower

This element is used to place a tower location at an airport. This element is not allowed to contain other data and must be terminated with ‘/>’.


<Tower
lat="41.35186742"
lon="-89.15308328"
alt="199.33918762"/>


Attribute

Description

Acceptable Values

lat Latitude of tower. Optional.

-90 to +90 degrees

Format can be decimal or degrees-minutes-seconds

lon Longitude of tower. Optional.

-180 to +180 degrees

Format can be decimal or degrees-minutes-seconds

alt Altitude of tower. Optional. Any floating point value. Altitude may be suffixed by ‘M’ or ‘F’ to designate meters or feet. Default is meters.

Hope this helps,
 
Tom,

Thanks for the re-direct to the BGL Compiler SDK. Indeed, it says the element isn't allowed to contain other data but the stock KIAH Tower element includes coordinates for both the old and the new IAH control towers.

The new KIAH control tower coordinates are in <Tower> and the old KIAH control tower coordinates are in <SceneryObject> which is a child of <Tower>.

So, I guess it's the last set of coordinates in the Tower element that determine tower view??? - in the case of KIAH, the old control tower.

I'm sure this is straightforward to those that work with scenery all the time.

Thanks very much for helping out.

Bob
 
Because FSX allows multiple tower visual objects (scenery object) I think it is possible to get more than one associated with a <tower> object. I haven't looked at this for a while now as ADE extracts the scenery objects and makes them separate from the view point. As I recall we did this since it caused problems leaving them where they were. Jim Vile will remember I am sure :)
 
I believe the rule is that you may only have one Tower element. I guess you can put Scenery Object elements inside that (although not mentioned by the SDK, of course). But AFAIK these Scenery Object elements do not create another tower *view*.
 
You are right Tom. We can have only one tower viewpoint per airport. The attachment of objects to it is just a coding convenience (or inconvenience) dreamed up by the design team for FSX.
 
Here's the unedited <Tower> record from the stock FSX KIAH airport (0202, APX22210.bgl):

Code:
  <Tower
    lat="N29 59.06182"
    lon="W095 19.66084"
    alt="0.00M">
    <SceneryObject
      lat="N29 59.19698"
      lon="W095 21.09813"
      alt="0.0000M"
      altitudeIsAgl="TRUE"
      pitch="0.00"
      bank="0.00"
      heading="0.00"
      imageComplexity="VERY_SPARSE">
      <LibraryObject
        name="{F3509EA4-5817-46A5-9CD3-EDA3C449F25C}"
        scale="1.00"/>
    </SceneryObject>
[COLOR="Green"]<!-- according to DTD/Schema more than one scenery object in tower record is not allowed
    <SceneryObject
      lat="N29 59.06182"
      lon="W095 19.66084"
      alt="0.0000M"
      altitudeIsAgl="TRUE"
      pitch="0.00"
      bank="0.00"
      heading="0.00"
      imageComplexity="VERY_SPARSE">
      <LibraryObject
        name="{9D4A2F38-BCB7-4124-8DE2-B2811D962858}"
        scale="1.00"/>
    </SceneryObject>
-->[/COLOR]
  </Tower>

First set of coordinates is the new IAH control tower location. Coordinates within SceneryObject (the SceneryObject not commented out) are for the old control tower.

In a multiplayer ATC Controller session, the tower opens up on the old KIAH control tower coordinates. I guess what that means is that the last set of lat/lon coordinates within the <Tower> record determine the multiplayer ATC control tower view point.

Does that make sense?

Bob
 
Here's the unedited <Tower> record from the stock FSX KIAH airport (0202, APX22210.bgl):

Code:
  <Tower
    lat="N29 59.06182"
    lon="W095 19.66084"
    alt="0.00M">
    <SceneryObject
      lat="N29 59.19698"
      lon="W095 21.09813"
      alt="0.0000M"
      altitudeIsAgl="TRUE"
      pitch="0.00"
      bank="0.00"
      heading="0.00"
      imageComplexity="VERY_SPARSE">
      <LibraryObject
        name="{F3509EA4-5817-46A5-9CD3-EDA3C449F25C}"
        scale="1.00"/>
    </SceneryObject>
[COLOR="Green"]<!-- according to DTD/Schema more than one scenery object in tower record is not allowed
    <SceneryObject
      lat="N29 59.06182"
      lon="W095 19.66084"
      alt="0.0000M"
      altitudeIsAgl="TRUE"
      pitch="0.00"
      bank="0.00"
      heading="0.00"
      imageComplexity="VERY_SPARSE">
      <LibraryObject
        name="{9D4A2F38-BCB7-4124-8DE2-B2811D962858}"
        scale="1.00"/>
    </SceneryObject>
-->[/COLOR]
  </Tower>

First set of coordinates is the new IAH control tower location. Coordinates within SceneryObject (the SceneryObject not commented out) are for the old control tower.

In a multiplayer ATC Controller session, the tower opens up on the old KIAH control tower coordinates. I guess what that means is that the last set of lat/lon coordinates within the <Tower> record determine the multiplayer ATC control tower view point.

Does that make sense?

Bob

The Multi Tower will always be placed at the Tower View positon. The Tower View for KIAH is

<Tower
lat="N29 59.06182"
lon="W095 19.66084"
alt="0.00M">

This has nothing to do with a sceneryobject. However if a sceneryobject is located at the same lat/lon then whatever that piece of scenery is will also be at the same location.

The error is telling you that 2 or more sceneryobjects regardless of what they are cannot nest inside the <Tower </Tower>.

1. Many airports do not have a sceneryobject of any kind located with the Tower View.

2. Many airports have a sceneryobject (such as a Tower) that has the same lat/lon as the Tower view.

3. Some Airports have 2 or more (KIAH) sceneryobjects nesting in the Tower data and these will not compile until they are moved outside the airport record.

ADE must make a internal decision on which sceneryobject (if more then 2 exist)to keep and which it must move into the FSData record (outside the Airport record). During the developement of ADE it was decided to always keep and match the sceneryobject with the Tower View lat/lon and remove any other sceneryobjects that are placed by the artist who developed these for ACES.

For KIAH, since the 2nd sceneryobjects lat/lon matches the tower view of the second sceneryobject listed then that is the one that ADE keeps.

This is not a problem with FSX or Multiplayer Tower since you can move the Tower View (circle with the T) to any sceneryobject on the airport. Once you move the view point save the ad2 project file and compile. The Multi Tower Controller View will now be the new lat/lon set with ADE.

Example: If you want the Multiplayer Controller Tower View to be at the new tower then drag the pink circle to the new tower which is

<Tower
lat="N29 59.19698"
lon="W095 21.09813"

The following post explains it all (includes moving the Multiplayer Tower to a new location with ADE)

http://www.fsdeveloper.com/forum/showthread.php?t=11909&highlight=tower+view
 
Last edited:
Thanks, Jim

That's a remarkable post and goes into a lot of detail. Thank you. Your explanations are thorough, logical and very patient.

I must admit, however, that I am still confused.

When I open a Multiplayer Controller session at KIAH, the tower is placed at

<SceneryObject
lat="N29 59.19698"
lon="W095 21.09813"
</SceneryObject>

The tower isn't placed at

<Tower
lat="N29 59.06182"
lon="W095 19.66084"
alt="0.00M">

I'm not using ADE and I do not want to move the tower view. My interest in this topic was actually to determine what file and which records FS uses to
center LayerRangeRings in the CustomDraw fs9gps:Map element in a multiplayer ATC session. The range rings are centered where FS places the tower. In the case of KIAH, its the SceneryObject coordinates and that led me to postulate that the last set of coordinates found in the Tower element were used to place the tower. But, I guess that I am simplifying things owing to a lack of understanding.

I need to learn how to edit a bgl file and re-compile ... change the KIAH Tower and SceneryObject coordinates to some remote lat/lons and see where my range rings go!

Thanks again for the time you put into your response.

Bob
 
Last edited:
Tower placement has nothing to do with any scenery object placement. In the FSX code it makes sense that any attached scenery object is at the same location as the viewpoint. As you have already identified the Tower Element in the Airport Record defines the position and you can have only one per airport. For example:

<Tower
lat="28.4785828739405"
lon="-81.7152039706707"
alt="16.459M">
</Tower>

Scenery objects inside or outside the tower record are a red herring as far as placement of the tower view is concerned.

I don't know anything about multi player and if it is using some other value that that above then I would have no idea why. It would not make too much sense since it is possible to have a tower placement without any physical object (The code above is for 12FA in FL).
 
Last edited:
Many thanks Jon,

Well, I give up for now. Whatever the reason, the multiplayer code chooses to place the KIAH tower at the same coordinates as those listed within the SceneryObject tags not the other coordinates in parent Tower tag. Beats me why.

I will study how to re-compile the bgl file after a simple edit of the KIAH XML. I'll substitute coordinates of some place in the Caribbean for the SceneryOject lat lon and see what happens. Same thing for the Tower lat lon. Maybe I will discover something.

I really do appreciate you, Tom and Jim for helping to educate me about scenery files and ADE. Maybe I should try my hand at airport design. I am naturally attracted to powerful applications like ADE just to see what they can do.

ขอบคุณ มาก ครับ

Bob
 
I have a similar problem. I am at an airfield in FSX and have no idea what scenery it is using. Whether it is stock or add on. The issue is that I am at YNUB which is a motel airfield in the bight of South Australia. The scenery in FSX has the runways (dirt), what seems like a taxiway (also dirt) and a hangar and a static aircraft and a number of water tanks. It also has a fenced square are with a fuel tanker and a few other airfield vehicles and structures (fuel bowser/tank) contained within the fenced area.

The actual location of these items is not placed correctly in relation to the airfield, eg. this fenced compound is on the other side of a main road. I think you may get the idea.

What I would like to do is use ADE to re locate these things to the appropriate locations.

Now the question is, how do I find what BGL file is being used by FSX to display this particular airfield scenery?

I have tried using the load stock airport menu in ADE but it is not there. Open BGL from file option and I can not find the YNUB BGL anywhere in the scenery folders. It is there some where as it displays in the scenery of FSX so how can I find where it is please?

Thanks in advance

Paul
 
Back
Top