131
edits
m (Categorize) |
m (indentation) |
||
Line 6: | Line 6: | ||
Each waypoint has eight parameters. They tend to be written in the following order: name, lat, lon, alt, ktas, on-ground, gear-down, flaps-down. All waypoints, except EOF, must have these, or the scenario may behave unpredictably. Furthermore, all waypoints are tagged with a wpt tag. Now, to go through the different parameters. | Each waypoint has eight parameters. They tend to be written in the following order: name, lat, lon, alt, ktas, on-ground, gear-down, flaps-down. All waypoints, except EOF, must have these, or the scenario may behave unpredictably. Furthermore, all waypoints are tagged with a wpt tag. Now, to go through the different parameters. | ||
name: can consist of anything. If you want to use a word or a number, it doesn't matter so long as the characters in it are allowed in XML. | * name: can consist of anything. If you want to use a word or a number, it doesn't matter so long as the characters in it are allowed in XML. | ||
lat: the model's latitude at the waypoint. | * lat: the model's latitude at the waypoint. | ||
lon: the model's longitude at the waypoint. | * lon: the model's longitude at the waypoint. | ||
alt: the model's altitude. | * alt: the model's altitude. | ||
ktas: Knots True AirSpeed of the model. | * ktas: Knots True AirSpeed of the model. | ||
on-ground: a boolean value expressed as an integer value of either 1 or 0. | * on-ground: a boolean value expressed as an integer value of either 1 or 0. | ||
gear-down: a boolean value expressed as an integer value of either 1 or 0. | * gear-down: a boolean value expressed as an integer value of either 1 or 0. | ||
flaps-down: a float value expressed a value between 0 and 1. | * flaps-down: a float value expressed a value between 0 and 1. | ||
on-ground need not necessarily be placed correctly. In the example, you will see that, for all waypoints, this value is set to zero. You may want to play around with this one. If you set it to 1 too early (for a landing), the aircraft will be thrust onto the ground sharply. If you set it late, then things should be okay. Or, it may appear to hover if you’ve set the altitude a bit high. | * on-ground need not necessarily be placed correctly. In the example, you will see that, for all waypoints, this value is set to zero. You may want to play around with this one. If you set it to 1 too early (for a landing), the aircraft will be thrust onto the ground sharply. If you set it late, then things should be okay. Or, it may appear to hover if you’ve set the altitude a bit high. | ||
Line 20: | Line 20: | ||
Once completed, be sure to save as an XML file in the AI/flightplans directory. | Once completed, be sure to save as an XML file in the AI/flightplans directory. | ||
== Tying Things Together == | == Tying Things Together == | ||
Next, you need to create the scenario XML file. For the example, I will simply borrow an existing one, and make modifications to it. I’ll choose aircraft_demo.xml. As you will see, you need PropertyList and scenario tags. A description is optional, but recommended. Then, there’s an entry for a model. It starts with an entry tag. Then, it’s given a callsign. The type is aircraft. There are different types you can specify for different kinds of scenarios; however, we’re just going to focus on the aircraft type. There are various classes as well. This one is set to jet transport. I think there’s a light class as well, but they all seem to behave the same to me. If someone else, more knowledgeable in this area could clarify things that would be helpful. Next is the model. Just set the path to the aircraft of your choice. It’s recommended that you use a low-poly aircraft from the AI directory, but a regular aircraft works fine as well. After that is the flightplan parameter. Simply set the path to your flightplan. Finally, there is an option to set your scenario to either simply terminate or repeat once completed. Enter a 1 for repeat, a 0 for no repeat. Remember to add all your end-tags when you have finished, and save it with a name other than the one you modified (if you chose to modify an existing scenario). | Next, you need to create the scenario XML file. For the example, I will simply borrow an existing one, and make modifications to it. I’ll choose aircraft_demo.xml. As you will see, you need PropertyList and scenario tags. A description is optional, but recommended. Then, there’s an entry for a model. It starts with an entry tag. Then, it’s given a callsign. The type is aircraft. There are different types you can specify for different kinds of scenarios; however, we’re just going to focus on the aircraft type. There are various classes as well. This one is set to jet transport. I think there’s a light class as well, but they all seem to behave the same to me. If someone else, more knowledgeable in this area could clarify things that would be helpful. Next is the model. Just set the path to the aircraft of your choice. It’s recommended that you use a low-poly aircraft from the AI directory, but a regular aircraft works fine as well. After that is the flightplan parameter. Simply set the path to your flightplan. Finally, there is an option to set your scenario to either simply terminate or repeat once completed. Enter a 1 for repeat, a 0 for no repeat. Remember to add all your end-tags when you have finished, and save it with a name other than the one you modified (if you chose to modify an existing scenario). |
edits