Board index FlightGear Development Scenery

Change runway designators

Questions and discussion about enhancing and populating the FlightGear world.

Re: Change runway designators

Postby dom_vc10 » Wed Sep 15, 2021 8:21 am

oh wow. I will try this later, thanks a lot :-)

I need to learn how to do this
dom_vc10
 
Posts: 339
Joined: Mon Jul 27, 2020 8:33 am
Location: CZ - LKTB
Version: nightly
OS: Linux Mint 20.2

Re: Change runway designators

Postby WoodSTokk » Wed Sep 15, 2021 12:51 pm

merspieler wrote in Wed Sep 15, 2021 8:20 am:Which file did you edit?


The original files from TerraSync are in
Code: Select all
/home/woodstokk/.fgfs/TerraSync/Terrain/e010n40/e016n49/

For local changes i have
Code: Select all
/home/woodstokk/.fgfs/TerraLocal/Terrain/e010n40/e016n49/

and the directory '/home/woodstokk/.fgfs/TerraLocal/' is added as additional Scenery in the Launcher.

Its not enough to copy only the airport! FG start the loading at the stg-file.
So i copied the file:
Code: Select all
3220170.btg.gz
3220170.stg
LKCM.btg.gz
LKTB.btg.gz

Then i unpacked the LKTB.btg.gz to receive LKTB.btg.
Edited this file in a Hex-Editor and repack it.
Done.

Next drawback is if FG find files in the Terrain-directory, it looks only in the same scenery-directory for other files.
So, if there are files for this tile also in Buildings, Details, Objects, Pylons or Roads, FG will load it only from the same scenery-directory.
In this case from TerraLocal. So searched and copied all files for this tile over from TerraSync to TerraLocal.

Last thing was to add LKTB.dat under /home/woodstokk/.fgfs/TerraLocal/NavData/apt/ and /home/woodstokk/.fgfs/TerraLocal/NavData/nav/
with the corrected lines.
WoodSTokk
 
Posts: 1077
Joined: Tue Oct 17, 2017 3:30 pm
Location: Milky Way/Sol/Earth/Europe
Callsign: SX-W57
IRC name: WoodSTokk
Version: 2020.4.0
OS: Debian Bullseye

Re: Change runway designators

Postby merspieler » Wed Sep 15, 2021 1:59 pm

WoodSTokk wrote in Wed Sep 15, 2021 12:51 pm:Edited this file in a Hex-Editor and repack it.


That's what I've just said above...


WoodSTokk wrote in Tue Sep 14, 2021 11:46 pm:
merspieler wrote in Tue Sep 14, 2021 9:15 am:Editing the actual runway markings? Afaik, you've got to regenerate the btg file (or maybe hex edit it :D )


Thats not true. As a test, i have changed runway numbers on KLAS one year before (Navaid updates).
If i have some spare time, i will look into this airport.
Nia (you&, she/her)

Please use gender neutral terms when referring to a group of people!

Be the change you wish to see in the world, be an ally to all!

Join the official matrix space
merspieler
 
Posts: 2242
Joined: Thu Oct 26, 2017 11:43 am
Location: Wish to be in YBCS
Pronouns: you&, she/her
Callsign: you&, she/her
IRC name: merspieler
Version: next
OS: NixOS

Re: Change runway designators

Postby WoodSTokk » Wed Sep 15, 2021 3:50 pm

merspieler wrote in Wed Sep 15, 2021 1:59 pm:That's what I've just said above...
merspieler wrote in Tue Sep 14, 2021 9:15 am:Editing the actual runway markings? Afaik, you've got to regenerate the btg file (or maybe hex edit it :D )

Yes, i know, sorry. But most user answer allways 'you must regenerate the btg and there is no other way' and thats not true.
As long as you dont touch the vertices and triangles, only the texture, it is possible.
WoodSTokk
 
Posts: 1077
Joined: Tue Oct 17, 2017 3:30 pm
Location: Milky Way/Sol/Earth/Europe
Callsign: SX-W57
IRC name: WoodSTokk
Version: 2020.4.0
OS: Debian Bullseye

Re: Change runway designators

Postby dom_vc10 » Fri Oct 15, 2021 10:05 am

legoboyvdlp wrote in Fri Sep 10, 2021 1:31 pm:No need to do any of that - it's already fixed for months already (since May). On FlightGear 2020.4 you can simply add a runway_rename.xml file. That allows you to remap the runway numbering. File format:

EIDW.runway_rename.xml
Code: Select all
<?xml version='1.0' encoding='ISO-8859-1'?>
<PropertyList>
   <runway-rename>
      <runway>
         <old-ident>10</old-ident>
         <new-ident>10R</new-ident>
      </runway>
      <runway>
         <old-ident>28</old-ident>
         <new-ident>28L</new-ident>
      </runway>
   </runway-rename>
</PropertyList>


So I tried this at EGGW and it worked like a charm however now the file was removed after re starting. Should I be putting the file in a custom folder, does FG re build the airports folders?
dom_vc10
 
Posts: 339
Joined: Mon Jul 27, 2020 8:33 am
Location: CZ - LKTB
Version: nightly
OS: Linux Mint 20.2

Re: Change runway designators

Postby wkitty42 » Fri Oct 15, 2021 12:26 pm

if you are using terrasync (aka automatic scenery downloading), do not place custom files in any of the directories that it manages... the terrasync process will remove files that do not exist on the server(s) in the same way that it adds files that exist on the server(s) but not locally...

you will need a custom scenery directory and may likely have to copy the existing files for the area in question into your custom scenery directory tree... this custom directory tree may require both Terrain and Objects trees and possibly also others used by OSM if you enable OSM...
"You get more air close to the ground," said Angalo. "I read that in a book. You get lots of air low down, and not much when you go up."
"Why not?" said Gurder.
"Dunno. It's frightened of heights, I guess."
User avatar
wkitty42
 
Posts: 9148
Joined: Fri Feb 20, 2015 4:46 pm
Location: central NC, USA
Callsign: wk42
Version: git next
OS: Kubuntu 20.04

Re: Change runway designators

Postby dom_vc10 » Fri Oct 15, 2021 1:36 pm

ok that will be it. I am placing them in the terrasync generated folders... I guess the sync in terrasync should have been the key for me :-) Thanks for the confirmation it makes sense now.
dom_vc10
 
Posts: 339
Joined: Mon Jul 27, 2020 8:33 am
Location: CZ - LKTB
Version: nightly
OS: Linux Mint 20.2

Re: Change runway designators

Postby dom_vc10 » Fri Dec 10, 2021 10:58 am

So I have found with the navigraph data there is a file named WPNAVAPT.txt . This lists all the runways. So now I am wondering if there is a way that I can generate a list of all runways per airport in FG? With that I could compare which have changed and in theory some scripting could come to create the runway change xml files.

Does anyone know if it's possible to generate the list of runways per airport in FG?
dom_vc10
 
Posts: 339
Joined: Mon Jul 27, 2020 8:33 am
Location: CZ - LKTB
Version: nightly
OS: Linux Mint 20.2

Re: Change runway designators

Postby MariuszXC » Fri Dec 10, 2021 11:52 am

Probably can be done by a Python script or some such.
APT.dat format specification is public: https://developer.x-plane.com/article/a ... ification/ and (once decompressed) it is a plain text file.
According to the specs, lines with first number of {1, 16, 17} describe airports. Then a list of runways follows. A quote from documentation:
Subsequent rows define elements of an airport:

Runways (including helipads) follow the airport header row (one row per runway).
Pavement (taxiway/apron) definitions have a header row followed by an ordered list of nodes that define its boundaries...
INOP
MariuszXC
 
Posts: 1061
Joined: Tue May 18, 2021 5:38 pm
Location: Europe
Callsign: SP-MRM
Version: 2020.4
OS: Ubuntu 16.04

Re: Change runway designators

Postby merspieler » Fri Dec 10, 2021 1:14 pm

parsing of the apt.dat is very easy... so yeah, should be doable in a few minutes if you know python and regex

If you need help, let me know... best ping me on matrix
Nia (you&, she/her)

Please use gender neutral terms when referring to a group of people!

Be the change you wish to see in the world, be an ally to all!

Join the official matrix space
merspieler
 
Posts: 2242
Joined: Thu Oct 26, 2017 11:43 am
Location: Wish to be in YBCS
Pronouns: you&, she/her
Callsign: you&, she/her
IRC name: merspieler
Version: next
OS: NixOS

Re: Change runway designators

Postby jojo2357 » Thu Apr 13, 2023 9:06 pm

I am working on a tool to parse free FAA ARINC 424 [on my github](https://github.com/jojo2357/flightgear-star-sid-manager). I can parse apt.dat, and parse the FAA's data. While it is a *huge* headache to figure out exactly what runways are now where, I can do good enough for me.

However, **my rename files do not work**. I know that my procedure files work, and I placed the rename files in the same directory as the renames, but alas nothing. no mention in the logs, but i can halt the game loading if i make a circular reference (rename A to B and B to A).

One example I have used is KSNA due to its high number of procedures and having renamed runways. The rename file is [here](https://github.com/jojo2357/flightgear- ... rename.xml) and the procedures are [here](https://github.com/jojo2357/flightgear- ... edures.xml).

If I spelled something wrong, im going to be so sad.

Linux, fg 2020.3.18 from flatpak
jojo2357
 
Posts: 10
Joined: Fri Apr 07, 2023 8:44 pm

Re: Change runway designators

Postby polly » Thu Apr 13, 2023 10:15 pm

I added a log line and I can't see the runway_rename function getting called. Do you need to have LevelD files installed somewhere to cause the renaming to get called ?

There's no xml tag thingy at the top of your rename file but that doesn't seem to be the issue.
User avatar
polly
 
Posts: 956
Joined: Thu Nov 04, 2010 3:45 pm

Re: Change runway designators

Postby jojo2357 » Thu Apr 13, 2023 10:32 pm

I have the levelD installed (check the same folder as the rename in the git) which references the renamed runways (20B and 02B)
jojo2357
 
Posts: 10
Joined: Fri Apr 07, 2023 8:44 pm

Re: Change runway designators

Postby polly » Thu Apr 13, 2023 10:47 pm

Your procedures file is throwing an error that EOF is reached while a <Type> tag is unclosed. I don't have the eyes to search through such a huge file. Is it possible to try with a much smaller procedures file ?
I have a log item in flightgear/src/Airports/airport.cxx:
Code: Select all
void FGAirport::parseRunwayRenameData(SGPropertyNode* aRoot)
{
    SGPropertyNode* overrideNode = aRoot->getChild("runway-rename");
    for (auto rnm : overrideNode->getChildren("runway")) {
        const std::string oldIdent = rnm->getStringValue("old-ident");
        const std::string newIdent = rnm->getStringValue("new-ident");
        SG_LOG(SG_NAVAID, SG_ALERT, ident() << ": runway rename old: " << oldIdent << " new: " << newIdent );
        if (oldIdent.empty() || newIdent.empty()) {
            SG_LOG(SG_NAVAID, SG_WARN, ident() << ": runway rename: Skipping bad runway rename entry");
            continue;
        }



and it simply isn't getting called, I'm assuming ( guessing ) there must be a good procedures.xml in this directory ?
User avatar
polly
 
Posts: 956
Joined: Thu Nov 04, 2010 3:45 pm

Re: Change runway designators

Postby jojo2357 » Thu Apr 13, 2023 11:16 pm

I don't understand that. WebStorm validated the XML, so I can't imagine how there is an unclosed tag. Try KBEH.~400 Line procedures with 5 approaches, no sids or stars and the approaches do not show up in the route manager.
jojo2357
 
Posts: 10
Joined: Fri Apr 07, 2023 8:44 pm

PreviousNext

Return to Scenery

Who is online

Users browsing this forum: No registered users and 5 guests