BIS fnc diagBulletCam: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (revert + fix)
Tag: Undo
m (Some wiki formatting)
 
(12 intermediate revisions by the same user not shown)
Line 2: Line 2:


|game1= arma3
|game1= arma3
|version1= 1.00
|version1= 1.00


Line 15: Line 14:
|r1= [[Boolean]] - [[true]] when done
|r1= [[Boolean]] - [[true]] when done


|x1= <code>[[player]] [[call]] [[BIS_fnc_diagBulletCam]];</code>
|x1= <sqf>player call BIS_fnc_diagBulletCam;</sqf>


|x2= <code>{{cc|bullet camera will be removed after 10s}}
|x2= <sqf>
_unit = [[player]];
// bullet camera will be removed after 10s
_unit [[call]] [[BIS_fnc_diagBulletCam]];
_unit = player;
_ehIndex = _unit [[getVariable]] "bis_fnc_diagBulletCam_fired";
_unit call BIS_fnc_diagBulletCam;
[[sleep]] 10;
_ehIndex = _unit getVariable "BIS_fnc_diagBulletCam_fired";
_unit [[removeEventHandler]] ["[[Arma_3:_Event_Handlers#Fired|fired]]", _ehIndex];</code>
sleep 10;
_unit removeEventHandler ["fired", _ehIndex];
</sqf>


|seealso= [[:Category:Event_Handlers|Event Handlers]], [[:Category:Command_Group:_Camera_Control|Camera Control Commands]]
|seealso= [[:Category:Event_Handlers|Event Handlers]] [[:Category:Command_Group:_Camera_Control|Camera Control Commands]]
}}
}}

Latest revision as of 12:30, 13 July 2022

Hover & click on the images for description

Description

Description:
Add a "bullet camera" to shots fired by the specified unit.
Execution:
call
Groups:
Diagnostic

Syntax

Syntax:
unit call BIS_fnc_diagBulletCam
Parameters:
unit: Object - the shooting unit. Can be a vehicle.
Return Value:
Boolean - true when done

Examples

Example 1:
player call BIS_fnc_diagBulletCam;
Example 2:
// bullet camera will be removed after 10s _unit = player; _unit call BIS_fnc_diagBulletCam; _ehIndex = _unit getVariable "BIS_fnc_diagBulletCam_fired"; sleep 10; _unit removeEventHandler ["fired", _ehIndex];

Additional Information

See also:
Event Handlers Camera Control Commands

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