BIS fnc ambientFlyby: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (added note about captive behaviour)
Line 8: Line 8:
____________________________________________________________________________________________
____________________________________________________________________________________________


| Spawns an air unit that moves from point A to point B, never engaging nor being engaged. It is set as captive and will despawn once it reaches its destination.{{Informative|The function will always set [[captive]] to [[true]] for the vehicle. Therefore the side will always be [[civilian]].}} |DESCRIPTION=
| Spawns an air unit that moves from point A to point B, never engaging nor being engaged. It is set as captive and will despawn once it reaches its destination.{{Informative | Created vehicle is [[setCaptive|set captive]], making its side [[civilian]].}} |DESCRIPTION=
____________________________________________________________________________________________
____________________________________________________________________________________________


| <nowiki>[[0,0,0],[100,100,100],100,"NORMAL","B_Heli_Light_01_F",WEST]</nowiki> call '''BIS_fnc_ambientFlyby'''; |SYNTAX=
| [startPos, endPos, altitude, speedMode, classname, side] call [[BIS_fnc_ambientFlyby]]; |SYNTAX=


|p1= [[Array]] - Array containing start position where air unit spawns. Format [x,y,z]. |Parameter1=
|p1= startPos: [[PositionATL]] - start position of the air unit |Parameter1=


|p2= [[Array]] - Array containing end position where air unit moves to and despawns. Format [x,y,z]. |Parameter2=
|p2= endPos: [[PositionAGL]] - end position where the air unit moves to and despawns |Parameter2=


|p3= [[Number]] - Height at which air unit will spawn and fly. |=
|p3= altitude: [[Number]] - (Optional, default 100) height at which air unit will spawn and fly above ground level |Parameter3=
|p4= [[String]] - String detailing speed at which air unit travels. Possible values "LIMITED", "NORMAL" and "FULL". |=
|p5= [[String]] - Vehicle classname of air unit to spawn. Viewable in CfgVehicles. |=
|p6= [[Side]] - Side which vehicle belongs to. |=


| [[Boolean]] - True if function executed successfully. |RETURNVALUE=
|p4= speedMode: [[String]] - (Optional, default "NORMAL") [[speedMode|speed mode]] at which air unit travels. Possible values are "LIMITED", "NORMAL" and "FULL" |Parameter4=
 
|p5= classname: [[String]] - (Optional, default "B_Heli_Light_01_F") vehicle classname defined in [[CfgVehicles]] |Parameter5=
 
|p6= side: [[Side]] - (Optional, default [[west]]) side to which the vehicle belongs |Parameter6=
 
| [[Boolean]] - [[true]] if function executed successfully. |RETURNVALUE=
____________________________________________________________________________________________
____________________________________________________________________________________________


|x1= <code><nowiki>ambFlyby = [[200,200,50],[250,250,75]]</nowiki> call BIS_fnc_ambientFlyBy; //Spawns a Littlebird that flies from position 200,200,50 to 250,250,75 at height 100 and Normal speed.</code> |=  
|x1= <code>{{cc|spawns a Littlebird that flies from position 200,200,50 to 250,250,75 at altitude 100 and normal speed}}
|x2 = <code><nowiki>ambFlyby = [getposATL player, getposATL opforUnit, 400, "FULL", "B_Heli_Light_01_Armed_F", WEST]</nowiki> call BIS_fnc_ambientFlyBy;</code> |=
[<nowiki/>[200,200,50], [250,250,75]] [[call]] [[BIS_fnc_ambientFlyby]];</code> |Example1=
 
|x2 = <code>[<nowiki/>[[getPosATL]] [[player]], [[getPosATL]] opforUnit, 400, "FULL", "B_Heli_Light_01_Armed_F", [[west]]] [[call]] [[BIS_fnc_ambientFlyby]];</code> |Example2=
____________________________________________________________________________________________
____________________________________________________________________________________________


| |SEEALSO=
| [[createVehicle]], [[BIS_fnc_spawnVehicle]] |SEEALSO=
 
}}
}}



Revision as of 21:55, 23 September 2019


Hover & click on the images for description

Description

Description:
Spawns an air unit that moves from point A to point B, never engaging nor being engaged. It is set as captive and will despawn once it reaches its destination.
Created vehicle is set captive, making its side civilian.
Execution:
call
Groups:
Uncategorised

Syntax

Syntax:
[startPos, endPos, altitude, speedMode, classname, side] call BIS_fnc_ambientFlyby;
Parameters:
startPos: PositionATL - start position of the air unit
endPos: PositionAGL - end position where the air unit moves to and despawns
altitude: Number - (Optional, default 100) height at which air unit will spawn and fly above ground level
speedMode: String - (Optional, default "NORMAL") speed mode at which air unit travels. Possible values are "LIMITED", "NORMAL" and "FULL"
classname: String - (Optional, default "B_Heli_Light_01_F") vehicle classname defined in CfgVehicles
side: Side - (Optional, default west) side to which the vehicle belongs
Return Value:
Boolean - true if function executed successfully.

Examples

Example 1:
// spawns a Littlebird that flies from position 200,200,50 to 250,250,75 at altitude 100 and normal speed [[200,200,50], [250,250,75]] call BIS_fnc_ambientFlyby;
Example 2:
[getPosATL player, getPosATL opforUnit, 400, "FULL", "B_Heli_Light_01_Armed_F", west] call BIS_fnc_ambientFlyby;

Additional Information

See also:
createVehicleBIS_fnc_spawnVehicle

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