BIS fnc traceBullets: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
mNo edit summary
m (Some wiki formatting)
 
(34 intermediate revisions by 4 users not shown)
Line 1: Line 1:
{{RV|type=function


{{Function|= Comments
|game1= arma3
____________________________________________________________________________________________
|version1= 1.00


| arma3 |= Game name
|gr1= Diagnostic


|1.00|= Game version
|descr= Visualise unit's bullet trajectories. Can only be used on one shooter in a single instance.<br>
____________________________________________________________________________________________
If you want to change the unit, first set <sqf inline>BIS_tracedShooter = nil</sqf> ''then'' execute the script again.


| <pre>/*
|s1= [unit, number] call [[BIS_fnc_traceBullets]]


Description:
|p1= unit: [[Object]]
Visualizes bullet trajectories.
NOTE: Currently works only for player in a single instance


Parameter(s):
|p2= number: [[Number]] - (Optional, default 20) maximum displayed trajectories
0: OBJECT - unit who's bullets will be visualized
1: (Optional) NUMBER - max trajectories (default 10)


Returns:
|r1= [[Nothing]]
Nothing
*/


</pre><small>''(Placeholder description extracted from the function header by [[BIS_fnc_exportFunctionsToWiki]])''</small> |= Description
|x1= <sqf>[player] spawn BIS_fnc_traceBullets;</sqf>
____________________________________________________________________________________________


| <!-- [] call [[BIS_fnc_traceBullets]]; --> |= Syntax
|x2= <sqf>[player, 50] spawn BIS_fnc_traceBullets;</sqf>


|p1= |= Parameter 1
|x3= <sqf>[player, 0] spawn BIS_fnc_traceBullets; // remove bullet tracing</sqf>|seealso= [[drawLine3D]]
 
}}
| |= Return value
____________________________________________________________________________________________
 
|x1= <code><nowiki>[</nowiki>[[player]]] [[spawn]] [[BIS_fnc_traceBullets]];</code> |=
 
|x2= <code><nowiki>[</nowiki>[[player]], 20] [[spawn]] [[BIS_fnc_traceBullets]];</code> |=
 
|x3= <code><nowiki>[</nowiki>[[player]], 0] [[spawn]] [[BIS_fnc_traceBullets]]; //remove bullet tracing</code> |=  
 
____________________________________________________________________________________________
 
| |= See also


{{Note
|user= Benargee
|timestamp= 20150326232500
|text= Shooting bullets over water will show wavy lines that move with motion of the waves. This is probably due to using the wrong getPos variants when drawing 3D lines.
|game= arma3
|version= 1.40
}}
}}
<h3 style="display:none">Notes</h3>
<dl class="command_description">
<!-- Note Section BEGIN -->
<!-- Note Section END -->
</dl>
<h3 style="display:none">Bottom Section</h3>
[[Category:Function Group: Misc|{{uc:traceBullets}}]]
[[Category:Functions|{{uc:traceBullets}}]]
[[Category:{{Name|arma3}}: Functions|{{uc:traceBullets}}]]
<!-- CONTINUE Notes -->
<dl class="command_description">
<dd class="notedate">Posted on March 26, 2015 - 23:25 (UTC)</dd>
<dt class="note">[[User:Benargee|Benargee]]</dt>
<dd class="note">
(A3 1.40)Shooting bullets over water will show wavy lines that move with motion of the waves. This is probably due to using the wrong getPos variants when drawing 3D lines.
</dd>
</dl>
<!-- DISCONTINUE Notes -->

Latest revision as of 14:25, 27 July 2022

Hover & click on the images for description

Description

Description:
Visualise unit's bullet trajectories. Can only be used on one shooter in a single instance.
If you want to change the unit, first set BIS_tracedShooter = nil then execute the script again.
Execution:
call
Groups:
Diagnostic

Syntax

Syntax:
[unit, number] call BIS_fnc_traceBullets
Parameters:
unit: Object
number: Number - (Optional, default 20) maximum displayed trajectories
Return Value:
Nothing

Examples

Example 1:
[player] spawn BIS_fnc_traceBullets;
Example 2:
[player, 50] spawn BIS_fnc_traceBullets;
Example 3:
[player, 0] spawn BIS_fnc_traceBullets; // remove bullet tracing

Additional Information

See also:
drawLine3D

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
Benargee - c
Posted on Mar 26, 2015 - 23:25 (UTC)

Shooting bullets over water will show wavy lines that move with motion of the waves. This is probably due to using the wrong getPos variants when drawing 3D lines.