BIS fnc effectFiredRifle: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - "<code>([^<]*)\[\[([a-zA-Z][a-zA-Z0-9_]+)\]\]([^<]*) *<\/code>" to "<code>$1$2$3</code>")
m (Text replacement - "(\|[pr][0-9]+ *= *[^- ]*) *- *T([a-z ])" to "$1 - t$2")
 
(2 intermediate revisions by the same user not shown)
Line 12: Line 12:
|s1= [unit, nil, nil, nil, ammoType] call [[BIS_fnc_effectFiredRifle]]
|s1= [unit, nil, nil, nil, ammoType] call [[BIS_fnc_effectFiredRifle]]


|p1= unit: [[Object]] - The unit, the effect should be added to
|p1= unit: [[Object]] - the unit, the effect should be added to


|p2= nil: [[Nothing]]
|p2= nil: [[Nothing]]
Line 20: Line 20:
|p4= nil: [[Nothing]]
|p4= nil: [[Nothing]]


|p5= ammoType: [[String]] - The type of ammo the effect should be triggered for
|p5= ammoType: [[String]] - the type of ammo the effect should be triggered for


|r1= [[Nothing]]
|r1= [[Nothing]]


|x1= <code>unit addEventHandler ["Fired",  
|x1= <sqf>unit addEventHandler ["Fired",  
{
{
   [[Magic Variables#this|_this]] call BIS_fnc_effectFiredRifle;
   _this call BIS_fnc_effectFiredRifle;
}];</code>
}];</sqf>


|seealso= [[addEventHandler]] [[Arma_3:_Event_Handlers#Fired | Fired Event Handler]]
|seealso= [[addEventHandler]] [[Arma_3:_Event_Handlers#Fired | Fired Event Handler]]
}}
}}

Latest revision as of 16:50, 8 November 2023

Hover & click on the images for description

Description

Description:
Used to add an effect to fired bullets. Should be executed from Fired Event Handler.
Execution:
call
Groups:
Effects

Syntax

Syntax:
[unit, nil, nil, nil, ammoType] call BIS_fnc_effectFiredRifle
Parameters:
unit: Object - the unit, the effect should be added to
nil: Nothing
nil: Nothing
nil: Nothing
ammoType: String - the type of ammo the effect should be triggered for
Return Value:
Nothing

Examples

Example 1:
unit addEventHandler ["Fired", { _this call BIS_fnc_effectFiredRifle; }];

Additional Information

See also:
addEventHandler Fired Event Handler

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