wolle Posted June 29, 2020 Posted June 29, 2020 Is there a way, using lua code, to get the length of the runway(s) of a particular airbase? In other words, can some one translate this pseudo-code into real code? Thanks! airbase = Airbase.getByName("SomeAirfield") length = airbase:getRunwayLength() [sIGPIC][/sIGPIC] Intel Core I7 4820K @4.3 GHz, Asus P9X79 motherboard, 16 GB RAM @ 933 MHz, NVidia GTX 1070 with 8 GB VRAM, Windows 10 Pro
funkyfranky Posted June 29, 2020 Posted June 29, 2020 Is there a way, using lua code, to get the length of the runway(s) of a particular airbase? Not really. You can use the getParking function to get the runway spawn points. The distance between these points is a good approximation (lower bound) of the runway length. The Moose ATIS class uses this, for example. A warrior's mission is to foster the success of others. i9-12900K | RTX 4090 | 128 GB Ram 3200 MHz DDR-4 | Quest 3 RAT - On the Range - Rescue Helo - Recovery Tanker - Warehouse - Airboss
wolle Posted June 29, 2020 Author Posted June 29, 2020 Thanks, that's a smart way of doing it. For now, however, what I'll prolly do is measure the runway length by hand in the ME, and collect them in a lua table. That obviously has the disadvantage that this table must be updated by hand when they make changes to the maps.... [sIGPIC][/sIGPIC] Intel Core I7 4820K @4.3 GHz, Asus P9X79 motherboard, 16 GB RAM @ 933 MHz, NVidia GTX 1070 with 8 GB VRAM, Windows 10 Pro
=475FG= Dawger Posted July 1, 2020 Posted July 1, 2020 Runway length for the primary runway is available by clicking on the airfield in the f10 map
Hardcard Posted July 2, 2020 Posted July 2, 2020 I'd check the airbase object description (or the database), perhaps the length of the runway(s) is listed there. Like pmiceli said, if runway length is displayed in the F10 map, it means it's stored somewhere... just need to figure out where and whether it's accessible via scripting. [sIGPIC][/sIGPIC]
Recommended Posts