compatibleMagazines: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - "\|branch= *dev " to "")
m (Text replacement - " (\|[pr][0-9]+ *= *[^-]+) *- *A([a-z])" to " $1 - a$2")
Line 13: Line 13:
|p1= weapon: [[String]] - Weapon class name
|p1= weapon: [[String]] - Weapon class name


|r1= [[Array]] of [[String]]s - All magazines that can be loaded in '''any muzzle''' of the given weapon.
|r1= [[Array]] of [[String]]s - all magazines that can be loaded in '''any muzzle''' of the given weapon.


|s2= [[compatibleMagazines]] [weapon, muzzle]
|s2= [[compatibleMagazines]] [weapon, muzzle]
Line 21: Line 21:
|p22= muzzle: [[String]] - Muzzle name
|p22= muzzle: [[String]] - Muzzle name


|r2= [[Array]] of [[String]]s - All magazines that can be loaded in the given muzzle of the given weapon.
|r2= [[Array]] of [[String]]s - all magazines that can be loaded in the given muzzle of the given weapon.


|x1= <sqf>compatibleMagazines "arifle_Katiba_GL_F";</sqf>
|x1= <sqf>compatibleMagazines "arifle_Katiba_GL_F";</sqf>

Revision as of 12:39, 8 November 2023

Hover & click on the images for description

Description

Description:
Returns all magazines that can be loaded in the given weapon.
Groups:
Weapons

Syntax

Syntax:
compatibleMagazines weapon
Parameters:
weapon: String - Weapon class name
Return Value:
Array of Strings - all magazines that can be loaded in any muzzle of the given weapon.

Alternative Syntax

Syntax:
compatibleMagazines [weapon, muzzle]
Parameters:
weapon: String - Weapon class name
muzzle: String - Muzzle name
Return Value:
Array of Strings - all magazines that can be loaded in the given muzzle of the given weapon.

Examples

Example 1:
compatibleMagazines "arifle_Katiba_GL_F";
Example 2:
compatibleMagazines ["arifle_Katiba_GL_F", "this"];
Example 3:
compatibleMagazines ["arifle_Katiba_GL_F", "EGLM"];

Additional Information

See also:
compatibleItems BIS_fnc_compatibleMagazines canAdd

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