20,741
edits
(→Ideas) |
(→Ideas) |
||
| Line 94: | Line 94: | ||
} # foreach aircraft | } # foreach aircraft | ||
</syntaxhighlight> | </syntaxhighlight> | ||
(if I didn't make any typos, you can directly paste this into the Debug/Nasal console and execute the snippet) | |||
Depending on your background this may seem too simple at first, or maybe a bit intimidating given those three nested foreach loops - but what it is really doing there is using all sorts of "variables" (aircraft, airport, objective) and creating combinations of all variables to create different missions. Equally, those variables could be randomied - e.g. to pick different groundspeeds, altitudes, time of day etc | |||
Such a stub could be easily populated to create real missions using geo.nas helpers. | |||
So all the building blocks are there - and we can even walk people through the whole who are completely new to Nasal, or programming altogether - it's mainly a matter of motivation and spare time, not so much skills/expertise - you'll learn along the way. That's how Thorsten created the Advanced Weather system, too. | |||
You may want to dabble a bit with the Nasal snippet above - it can easily be extended.<ref>{{cite web | |||
|url = https://forum.flightgear.org/viewtopic.php?p=218256#p218256 | |||
|title = <nowiki> Re: Tutorials/Missions/Adventures: requests for features </nowiki> | |||
|author = <nowiki> Hooray </nowiki> | |||
|date = Sep 11th, 2014 | |||
|added = Sep 11th, 2014 | |||
|script_version = 0.40 | |||
}}</ref> | |||
== Related == | == Related == | ||
{{Appendix}} | {{Appendix}} | ||