do: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Text replacement - "\| *((\[\[[a-zA-Z0-9_ |()]+\]\],? ?)+) * \}\}" to "|seealso= $1 }}") |
Lou Montana (talk | contribs) |
||
Line 26: | Line 26: | ||
<code>{ | <code>{ | ||
[[while]] {![[canStand]] [[Magic Variables|_x]] && [[alive]] [[Magic Variables|_x]]} [[do]] { | [[while]] {![[canStand]] [[Magic Variables|_x]] && [[alive]] [[Magic Variables|_x]]} [[do]] { | ||
[[Magic Variables|_x]] [[setDamage]] ([[damage]] [[_x]] - 0.01); | [[Magic Variables|_x]] [[setDamage]] ([[damage]] [[Magic Variables#x|_x]] - 0.01); | ||
}; | }; | ||
} [[forEach]] [[units]] [[group]] unitname;</code> | } [[forEach]] [[units]] [[group]] unitname;</code> |
Revision as of 12:58, 25 February 2021
Description
- Description:
- Description needed
- Groups:
- Program Flow
Syntax
- Syntax:
- Syntax needed
- Parameters:
- construct: One of:
- While Type (while)
- With Type (with)
- For Type (for)
- Switch Type (switch)
- code: Code
- Return Value:
- Return value needed
Examples
- Example 1:
while { b > a } do { a = a + 1 };
- Example 2:
- Repair all members of a group to such a level that they are able to stand up:
{ while {!canStand _x && alive _x} do { _x setDamage (damage _x - 0.01); }; } forEach units group unitname;
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