BIS fnc assignPlayerRole: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - " <h3 style="display:none">Notes</h3> <dl class="command_description"> <!-- Note Section BEGIN --> <!-- Note Section END --> </dl>" to "")
m (Text replacement - "<code> *([^<|{]*) *<\/code>" to "<sqf>$1</sqf>")
 
(22 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{Function|Comments=
{{RV|type=function


| tkoh |Game name=
|game1= tkoh
|version1= 1.00


|1.00|Game version=
|game2= arma3
|version2= 0.50


|gr1 = Object Manipulation |GROUP1=
|gr1= Object Manipulation


|Eff= local |= Effect
|eff= local


| Ensures the player can only get in the specific vehicle role. |DESCRIPTION=
|descr= Ensures the player can only get in the specific vehicle role.


| [vehicle, role, path] call [[BIS_fnc_assignPlayerRole]] |SYNTAX=
|s1= [vehicle, role, path] call [[BIS_fnc_assignPlayerRole]]


|p1= vehicle: [[Object]] - targeted vehicle |PARAMETER1=
|p1= vehicle: [[Object]] - targeted vehicle


|p2= role: [[String]] - can be one of:
|p2= role: [[String]] - can be one of:
Line 20: Line 22:
* "commander"
* "commander"
* "cargo"
* "cargo"
* "turret" |PARAMETER2=
* "turret"


|p3= path: [[Array]] or [[Number]] - the turret path |PARAMETER3=
|p3= path: [[Array]] or [[Number]]s - the turret path


| [[Boolean]] - [[true]] when done |RETURNVALUE=
|r1= [[Boolean]] - [[true]] when done


|x1= <code>[myVehicle, "turret", [0, 1]] [[call]] [[BIS_fnc_assignPlayerRole]];</code> |EXAMPLE1=
|x1= <sqf>[myVehicle, "turret", [0, 1]] call BIS_fnc_assignPlayerRole;</sqf>


| [[assignAsDriver]], [[assignAsGunner]], [[assignAsCommander]], [[assignAsCargo]], [[assignAsTurret]] |SEEALSO=
|seealso= [[assignAsDriver]] [[assignAsGunner]] [[assignAsCommander]] [[assignAsCargo]] [[assignAsTurret]]
}}
}}
<h3 style="display:none">Bottom Section</h3>
[[Category:Functions|{{uc:assignPlayerRole}}]]
[[Category:{{Name|tkoh}}: Functions|{{uc:assignPlayerRole}}]]
[[Category:{{Name|arma3}}: Functions|{{uc:assignPlayerRole}}]]

Latest revision as of 22:44, 12 July 2022

Hover & click on the images for description

Description

Description:
Ensures the player can only get in the specific vehicle role.
Execution:
call
Groups:
Object Manipulation

Syntax

Syntax:
[vehicle, role, path] call BIS_fnc_assignPlayerRole
Parameters:
vehicle: Object - targeted vehicle
role: String - can be one of:
  • "driver"
  • "gunner"
  • "commander"
  • "cargo"
  • "turret"
path: Array or Numbers - the turret path
Return Value:
Boolean - true when done

Examples

Example 1:
[myVehicle, "turret", [0, 1]] call BIS_fnc_assignPlayerRole;

Additional Information

See also:
assignAsDriver assignAsGunner assignAsCommander assignAsCargo assignAsTurret

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