Modules.nas: Difference between revisions

m
no edit summary
mNo edit summary
Line 17: Line 17:
Parts of this functionality were added to the [[Addons|addons]] manager earlier and have now been extracted to avoid code duplication.
Parts of this functionality were added to the [[Addons|addons]] manager earlier and have now been extracted to avoid code duplication.


{{caution|
Within a module {{code|setlistener()}} is overloaded and the default value for the 4th argument (runtime) is changed to 0, so the listener will run only if the property value has changed.
}}
=== Differences between add-ons and modules ===
=== Differences between add-ons and modules ===
While there are many similarities between add-ons and modules, some words on the differences:  
While there are many similarities between add-ons and modules, some words on the differences:  
Line 151: Line 154:
}}
}}


== HowTo / Examples ==
= HowTo / Examples =
 
== Nasal modules in an aircraft (e.g. for development) ==
=== Nasal modules in an aircraft (e.g. for development) ===
Nasal code for an aircraft is usually loaded by a XML declaration in the <aircraft>-set.xml file like this:
Nasal code for an aircraft is usually loaded by a XML declaration in the <aircraft>-set.xml file like this:
<syntaxhighlight lang="xml">
<syntaxhighlight lang="xml">
Line 214: Line 216:
|margin=10px |width=50%}}
|margin=10px |width=50%}}


== Existing modules ==
= Existing modules =
{| class="wikitable"
{| class="wikitable"
|-
|-
252

edits