BIS fnc swapVars: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) (Page filling - missing see also) |
m (template:command argument fix) |
||
Line 9: | Line 9: | ||
| Swaps the values of two variables '''passed as [[String]]'''.<br /> | | Swaps the values of two variables '''passed as [[String]]'''.<br /> | ||
Nothing is returned as this function modifies the variables directly. |= | Nothing is returned as this function modifies the variables directly. |DESCRIPTION= | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
| [variableName1, variableName2] call [[BIS_fnc_swapVars]] |= | | [variableName1, variableName2] call [[BIS_fnc_swapVars]] |SYNTAX= | ||
|p1= variableName1: [[String]] |= | |p1= variableName1: [[String]] |PARAMETER1= | ||
|p2= variableName2: [[String]] |= | |p2= variableName2: [[String]] |PARAMETER2= | ||
| [[Nothing]] |= | | [[Nothing]] |RETURNVALUE= | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
Line 25: | Line 25: | ||
["_a", "_b"] [[call]] [[BIS_fnc_swapVars]]; | ["_a", "_b"] [[call]] [[BIS_fnc_swapVars]]; | ||
_a == 2; {{codecomment|// true}} | _a == 2; {{codecomment|// true}} | ||
_b == 1; {{codecomment|// true}}</code> |= | _b == 1; {{codecomment|// true}}</code> |EXAMPLE1= | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
| |= | | |SEEALSO= | ||
}} | }} | ||
Revision as of 15:33, 7 April 2019
Description
- Description:
- Swaps the values of two variables passed as String.
Nothing is returned as this function modifies the variables directly. - Execution:
- call
- Groups:
- Uncategorised
Syntax
- Syntax:
- [variableName1, variableName2] call BIS_fnc_swapVars
- Parameters:
- variableName1: String
- variableName2: String
- Return Value:
- Nothing
Examples
- Example 1:
_a = 1; _b = 2; ["_a", "_b"] call BIS_fnc_swapVars; _a == 2; // true _b == 1; // true
Additional Information
- See also:
- See also needed
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