isEqualTypeParams: Difference between revisions
Jump to navigation
Jump to search
m (template:command argument fix) |
Lou Montana (talk | contribs) m (Text replacement - "|= Comments" to "|Comments=") |
||
Line 1: | Line 1: | ||
{{Command|= | {{Command|Comments= | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
Revision as of 19:04, 31 August 2019
Description
- Description:
- Compares types of all elements of input array to types of all elements of template array. Similar to isEqualTypeArray however this command is designed for fast validation of functions params, so there are differences:
- Groups:
- Uncategorised
Syntax
- Syntax:
- input isEqualTypeParams template
- Parameters:
- input: Anything - could be value of any type, but only type Array will be validated
- template: Array - array of expected types
- Return Value:
- Boolean
Examples
- Example 1:
[1,2,player,"10"] isEqualTypeParams [0,0,objNull,""]; //true 123 isEqualTypeParams [0,0,objNull,""]; //false [] isEqualTypeParams [0,0,objNull,""]; //false [1,2,player] isEqualTypeParams [0,0,objNull,""]; //false [1,2,player,"10",true] isEqualTypeParams [0,0,nil,""]; //true [1,2,getPos player,"10",true] isEqualTypeParams [0,0,nil,""]; //true
Additional Information
Notes
-
Report bugs on the Feedback Tracker and/or discuss them on the Arma Discord or on the Forums.
Only post proven facts here! Add Note