BIS fnc swapVars: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - " *\| *([Cc]omments|COMMENTS|[Gg]ame [Nn]ame|Game [Vv]ersion|Game Version \(number surrounded by NO SPACES\)|Multiplayer Arguments \("local" or "global"\)|Multiplayer Effects \("local" or "global"\)|Multiplayer Execution \("server" o...)
m (Text replacement - "<h3 style="display:none">Bottom Section</h3>" to "")
Line 27: Line 27:
}}
}}


<h3 style="display:none">Bottom Section</h3>
 


[[Category:Functions|{{uc:swapVars}}]]
[[Category:Functions|{{uc:swapVars}}]]

Revision as of 02:23, 18 January 2021

Hover & click on the images for description

Description

Description:
Swaps the values of two variables passed as String.
Nothing is returned as this function modifies the variables directly.
Execution:
call
Groups:
Variables

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