Difference between revisions of "BIS fnc moveToRespawnPosition"

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Generated by BIS_fnc_exportFunctionsToWiki)
 
m (template:command argument fix)
 
(2 intermediate revisions by 2 users not shown)
Line 4: Line 4:
  
 
| arma3 |= Game name
 
| arma3 |= Game name
 
+
|arg= local |= Arguments in MP
 
|1.00|= Game version
 
|1.00|= Game version
 
____________________________________________________________________________________________
 
____________________________________________________________________________________________
  
| <pre>/*
+
| Move given unit to given respawn position. Units moved to height <nowiki>>=</nowiki> 30m will start on parachute. Position [0,0,0] is blacklisted. This function must be executed where unit to be moved is [[local]] |DESCRIPTION=
 
 
Description:
 
Move a unit to the respawn position.
 
 
 
Parameter(s):
 
0: OBJECT
 
1:
 
STRING - move to marker position
 
OBJECT - move inside a vehicle (when seats are empty and not locked) or around it
 
ARRAY - move to precise [X,Y,Z] position
 
 
 
Returns:
 
BOOL
 
*/
 
 
 
</pre><small>''(Placeholder description extracted from the function header by [[BIS_fnc_exportFunctionsToWiki]])''</small> |= Description
 
 
____________________________________________________________________________________________
 
____________________________________________________________________________________________
  
| <!-- [] call [[BIS_fnc_moveToRespawnPosition]]; --> |= Syntax
+
| [unit, position, canBeDead] call [[BIS_fnc_moveToRespawnPosition]] |SYNTAX=
  
|p1= |= Parameter 1
+
|p1= unit: [[Object]] - unit to move |PARAMETER1=
 +
|p2= position: [[Object]], [[Group]], [[String]] or [[Array]]
 +
* [[Object]] or [[Group]] - Object or Group to move unit to. Move to the object position or inside an object if the object is a vehicle, or if group or unit is in vehicle and there is an empty seat
 +
* [[String]] - Marker to move unit to. Marker size will be used for random placement area and marker direction for unit direction
 +
* [[Array]] - Precise [[PositionAGL]] to move unit to. [x,y] array will be converted to [x,y,0]|PARAMETER1=
 +
|p3= canBeDead (Optional): [[Boolean]] - Whether or not dead are allowed:
 +
* [[true]] (Default) - Moved unit and/or object to which unit is moved can be dead
 +
* [[false]] - Both moved unit and vehicle or unit at position (if any) must be alive |PARAMETER1=
  
| |= Return value
+
| [[Boolean]] - [[true]]: move succeeded, [[false]]: move failed|RETURNVALUE=
 
____________________________________________________________________________________________
 
____________________________________________________________________________________________
  
|x1= <code></code> |=  
+
|x1= <code><nowiki>[</nowiki>[[player]], "SpawnMarker1"] [[call]] [[BIS_fnc_moveToRespawnPosition]];</code> |=  
 
____________________________________________________________________________________________
 
____________________________________________________________________________________________
  
| |= See also
+
| |SEEALSO=
  
 
}}
 
}}

Latest revision as of 15:32, 7 April 2019

Introduced with Arma 3 version 1.00
  Arguments of this scripting function have to be local to the client the function is executed on

Click on the images for descriptions

Introduced in

Game:
Arma 3
Version:
1.00

Description

Description:
Move given unit to given respawn position. Units moved to height >= 30m will start on parachute. Position [0,0,0] is blacklisted. This function must be executed where unit to be moved is local

Syntax

Syntax:
[unit, position, canBeDead] call BIS_fnc_moveToRespawnPosition
Parameters:
unit: Object - unit to move
position: Object, Group, String or Array
  • Object or Group - Object or Group to move unit to. Move to the object position or inside an object if the object is a vehicle, or if group or unit is in vehicle and there is an empty seat
  • String - Marker to move unit to. Marker size will be used for random placement area and marker direction for unit direction
  • Array - Precise PositionAGL to move unit to. [x,y] array will be converted to [x,y,0]
canBeDead (Optional): Boolean - Whether or not dead are allowed:
  • true (Default) - Moved unit and/or object to which unit is moved can be dead
  • false - Both moved unit and vehicle or unit at position (if any) must be alive
Return Value:
Boolean - true: move succeeded, false: move failed

Examples

Example 1:
[player, "SpawnMarker1"] call BIS_fnc_moveToRespawnPosition;

Additional Information

Execution:
call
Multiplayer:
-
See also:
See also needed

Notes

Only post proven facts here. Report bugs on the feedback tracker. Use the talk page or the forums for discussions.
Add New Note | How To

Notes

Bottom Section