then: Difference between revisions
Jump to navigation
Jump to search
mNo edit summary |
m (added see also) |
||
Line 1: | Line 1: | ||
{{Command|= Comments | |||
____________________________________________________________________________________________ | |||
| ofpr |= Game name | |||
|1.85|= Game version | |||
____________________________________________________________________________________________ | |||
| First or second element of array is executed depending on result of [[if]] condition. Result of the expression executed is returned as a result (result may be nothing). |= Description | |||
____________________________________________________________________________________________ | |||
| if '''then''' else |= Syntax | |||
|p1= if: [[If Type]] |= Parameter 1 | |||
|p2= else: [[Array]] |= Parameter 2 | |||
| [[Anything]] |= Return value | |||
____________________________________________________________________________________________ | |||
|x1 = <code>[[if]] (a>b) then <nowiki>{c=1}</nowiki> [[else]] <nowiki>{c=2}</nowiki></code> | = Example 1 | |||
|x2 = <code>[[if]] (a>b) then <nowiki>{c=1;c=2}</nowiki></code>| = Example 2 | |||
| [[Control Structures]] |= See also | |||
}} | |||
<h3 style="display:none">Notes</h3> | |||
<dl class="command_description"> | |||
<!-- Note Section BEGIN --> | |||
<!-- Note Section END --> | |||
</dl> | |||
<h3 style="display:none">Bottom Section</h3> | |||
[[Category:Scripting Commands|THEN]] | [[Category:Scripting Commands|THEN]] | ||
[[Category:Scripting Commands OFP 1.96|THEN]] | [[Category:Scripting Commands OFP 1.96|THEN]] | ||
[[Category:Scripting Commands ArmA|THEN]] | [[Category:Scripting Commands ArmA|THEN]] | ||
[[Category:ArmA: Control Structures|THEN]] | |||
[[Category:Command Group: Program Flow|THEN]] |
Revision as of 15:40, 15 January 2007
Description
- Description:
- First or second element of array is executed depending on result of if condition. Result of the expression executed is returned as a result (result may be nothing).
- Groups:
- Uncategorised
Syntax
Examples
Additional Information
- See also:
- Control Structures
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
Notes
Bottom Section
Categories:
- Scripting Commands
- Introduced with Operation Flashpoint: Resistance version 1.85
- Operation Flashpoint: Resistance: New Scripting Commands
- Operation Flashpoint: Resistance: Scripting Commands
- Command Group: Uncategorised
- Scripting Commands OFP 1.96
- Scripting Commands ArmA
- ArmA: Control Structures
- Command Group: Program Flow