Difference between revisions of "VN ms fnc aoTeleport"

From Savage Game Design Wiki
Jump to navigation Jump to search
m (Text replacement - " |e=" to " |a= |e=")
(Page filling)
 
(2 intermediate revisions by the same user not shown)
Line 1: Line 1:
 
 
{{Function
 
{{Function
  
Line 8: Line 7:
 
|a=
 
|a=
  
|e=
+
|e= global
  
 
|g1= general
 
|g1= general
  
|d= <pre>/*
+
|d= Teleports the player to the given position. Can spawn an ambient helicopter (uses [[VN_ms_fnc_spawnAmbHeli]]).
    Author: Wyqer, veteran29
 
    Date: 2019-08-25
 
  
    Description:
+
|s= [pos, radius, heliClass] call [[VN_ms_fnc_aoTeleport]]
        Teleports given unit to given position.
 
  
    Parameter(s):
+
|p1n= pos
        _pos        - Position to where the unit should be teleported               [POSITION, defaults to [0, 0, 0]]
+
|p1t= array
        _radius    - Radius around the given position for random placement        [NUMBER, defaults to 10]
+
|p1d= centre position to which the unit should be teleported
        _heliClass  - Classname of the helicopter to spawn, no spawn when not given [STRING, defaults to ""]
+
|p1v=
  
    Returns:
+
|p2n= radius
        Function reached the end [BOOL]
+
|p2t= number
*/
+
|p2d= '''exact distance''' from ''pos'' at a random (360°) angle
 +
|p2v= 10
  
</pre><small>''(Placeholder description extracted from the function header by '''LM_exportFunctionsToWiki.sqf''')''</small>
+
|p3n= heliClass
 
+
|p3t= string
|s= [] call [[vn_ms_fnc_aoTeleport]];
+
|p3d= helicopter classname - if empty, no helicopter will be spawned
 
+
|p3v= ""
|p1n=
 
|p1t=
 
|p1d=
 
|p1v=
 
  
|p2n=
+
|r1t= boolean
|p2t=
+
|r1d= function's success
|p2d=
 
|p2v=
 
  
|r1t=
+
|x1= <code>[getPos sogLeader, 5] call [[VN_ms_fnc_aoTeleport]];</code>
|r1d=
 
  
|x1= <code>-</code>
+
|x2= <code>[getPos sogLeader, 5, "VN_b_air_CH34_04_04"] call [[VN_ms_fnc_aoTeleport]];</code>
 
}}
 
}}

Latest revision as of 12:59, 22 February 2021

← back to Functions Introduced in S.O.G. Prairie Fire v1.00
by Wyqer, veteran29
Argument(s): n/a
Effect(s): global

Description

Teleports the player to the given position. Can spawn an ambient helicopter (uses VN_ms_fnc_spawnAmbHeli).

Syntax

Syntax
[pos, radius, heliClass] call VN_ms_fnc_aoTeleport
Parameters
pos: Array - centre position to which the unit should be teleported
radius: Number - (Optional, default 10) exact distance from pos at a random (360°) angle
heliClass: String - (Optional, default "") helicopter classname - if empty, no helicopter will be spawned
Return value
Boolean - function's success

Examples

Example 1
[getPos sogLeader, 5] call VN_ms_fnc_aoTeleport;
Example 2
[getPos sogLeader, 5, "VN_b_air_CH34_04_04"] call VN_ms_fnc_aoTeleport;