roleDescription: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
(example)
No edit summary
Line 31: Line 31:
[[Category:Arma 3: New Scripting Commands List|{{uc:{{PAGENAME}}}}]]
[[Category:Arma 3: New Scripting Commands List|{{uc:{{PAGENAME}}}}]]
[[Category:Scripting Commands Arma 3|{{uc:{{PAGENAME}}}}]]
[[Category:Scripting Commands Arma 3|{{uc:{{PAGENAME}}}}]]
<!-- CONTINUE Notes -->
<dl class="command_description">
<dd class="notedate">Posted on June 29, 2015 - 12:05 (UTC)</dd>
<dt class="note">[[User:Killzone Kid|Killzone Kid]]</dt>
<dd class="note">
One thing you should know about roles. When switching to units placed in editor on the fly in MP, it could mess up the role of the player. Could be bug, could be intended, but I would not recommend doing this. Create new unit dynamically if you need to switch to. Anyway, if role of the unit is messed up so is [[roleDescription]].
</dd>
</dl>
<!-- DISCONTINUE Notes -->

Revision as of 14:05, 29 June 2015

-wrong parameter ("arma3dev") defined!-[[:Category:Introduced with arma3dev version 1.47|1.47]]
Hover & click on the images for description

Description

Description:
Returns unit description set in Editor and visible on role selection screen in MP. Works in MP and SP.
Groups:
Uncategorised

Syntax

Syntax:
roleDescription unit
Parameters:
unit: Object
Return Value:
String

Examples

Example 1:
_playerRole = roleDescription player;

Additional Information

See also:
namegetPlayerUIDvehicleVarNameworldNamebriefingNamemissionNameserverName

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

[[Category:Introduced with arma3dev version 1.47]][[ Category: arma3dev: New Scripting Commands | ROLEDESCRIPTION]][[ Category: arma3dev: Scripting Commands | ROLEDESCRIPTION]]

Notes

Bottom Section

Posted on June 29, 2015 - 12:05 (UTC)
Killzone Kid
One thing you should know about roles. When switching to units placed in editor on the fly in MP, it could mess up the role of the player. Could be bug, could be intended, but I would not recommend doing this. Create new unit dynamically if you need to switch to. Anyway, if role of the unit is messed up so is roleDescription.