252
edits
(Add Extension functions new in FG 2020.1) |
|||
Line 2,347: | Line 2,347: | ||
The following functions have been added to the nasal core library and will be released with FlightGear version 2020.1. | The following functions have been added to the nasal core library and will be released with FlightGear version 2020.1. | ||
Befor the release they are available in the development branch "next". | Befor the release they are available in the development branch "next". | ||
=== isfunc() === | |||
Returns 1 if type or argument is a function, otherwise 0. | |||
=== isghost() === | |||
Returns 1 if type or argument is a ghost, otherwise 0. | |||
=== ishash() === | |||
Returns 1 if type or argument is a hash, otherwise 0. | |||
=== isint() === | === isint() === | ||
Line 2,357: | Line 2,366: | ||
|text = Returns 1 if x has a numeric value otherwise 0. | |text = Returns 1 if x has a numeric value otherwise 0. | ||
}} | }} | ||
=== isstr() === | === isstr() === | ||
Line 2,366: | Line 2,372: | ||
=== isvec() === | === isvec() === | ||
Returns 1 if type or argument is a vector, otherwise 0. | Returns 1 if type or argument is a vector, otherwise 0. | ||
=== vecindex() === | === vecindex() === | ||
Line 2,379: | Line 2,379: | ||
|text = Returns the index of value or nil, if value is not found in vector. | |text = Returns the index of value or nil, if value is not found in vector. | ||
}} | }} | ||
== Variables == | == Variables == | ||
Various global constants (technically variables) are provided for use in converting between different units. They are all found in {{fgdata file|Nasal/globals.nas|text=$FG_ROOT/Nasal/globals.nas}}. | Various global constants (technically variables) are provided for use in converting between different units. They are all found in {{fgdata file|Nasal/globals.nas|text=$FG_ROOT/Nasal/globals.nas}}. |
edits