selectLeader: Difference between revisions
Jump to navigation
Jump to search
Killzone Kid (talk | contribs) (example error) |
m (template:command argument fix) |
||
Line 11: | Line 11: | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
| Select a group's leader. In MP the group has to be [[local]] to the PC executing the command. Locality of the group can be checked with [[local]] command and group ownership with [[groupOwner]] command. |= | | Select a group's leader. In MP the group has to be [[local]] to the PC executing the command. Locality of the group can be checked with [[local]] command and group ownership with [[groupOwner]] command. |DESCRIPTION= | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
| groupName '''selectLeader''' unitName |= | | groupName '''selectLeader''' unitName |SYNTAX= | ||
|p1= groupName: [[Group]] |= | |p1= groupName: [[Group]] |PARAMETER1= | ||
|p2= unitName: [[Object]] |= | |p2= unitName: [[Object]] |PARAMETER2= | ||
| [[Nothing]] |= | | [[Nothing]] |RETURNVALUE= | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
|x1= <code>[[group]] [[player]] [[selectLeader]] [[player]];</code> |= | |x1= <code>[[group]] [[player]] [[selectLeader]] [[player]];</code> |EXAMPLE1= | ||
|x2= Make unit a leader from server:<code><nowiki>[</nowiki>[[group]] _unit, _unit] [[remoteExec]] ["selectLeader", [[groupOwner]] [[group]] _unit];</code> |= | |x2= Make unit a leader from server:<code><nowiki>[</nowiki>[[group]] _unit, _unit] [[remoteExec]] ["selectLeader", [[groupOwner]] [[group]] _unit];</code> |EXAMPLE1= | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
| [[formationLeader]], [[formLeader]], [[leader]], [[isFormationLeader]] |= | | [[formationLeader]], [[formLeader]], [[leader]], [[isFormationLeader]] |SEEALSO= | ||
}} | }} |
Revision as of 14:46, 7 April 2019
Description
- Description:
- Select a group's leader. In MP the group has to be local to the PC executing the command. Locality of the group can be checked with local command and group ownership with groupOwner command.
- Groups:
- Uncategorised
Syntax
- Syntax:
- groupName selectLeader unitName
- Parameters:
- groupName: Group
- unitName: Object
- Return Value:
- Nothing
Examples
- Example 1:
group player selectLeader player;
- Example 2:
- Make unit a leader from server:
[group _unit, _unit] remoteExec ["selectLeader", groupOwner group _unit];
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
Notes
Bottom Section
Categories:
- Scripting Commands
- Introduced with Arma version 1.00
- Arma: New Scripting Commands
- Arma: Scripting Commands
- Command Group: Uncategorised
- Scripting Commands: Global Effect
- Scripting Commands OFP Elite
- Scripting Commands ArmA
- Command Group: Groups
- Scripting Commands ArmA2
- Scripting Commands Arma 3
- Scripting Commands Take On Helicopters