Jump to content
juleshuxley

How to list all magazines that a weapon can take?

Recommended Posts

Looking at the arifle_MX_GL_Black_F's config suggests to me it can only take 100Rnd_65x39_caseless_black_mag magazines. This is stated in the magazines array entry:

magazines[] = {"100Rnd_65x39_caseless_black_mag"};

However, in game I find the rifle can take the 6.5 mm 30 Rnd Sand Mag

reload88.jpg
reload99.png

What gives? What's a surefire way I can find can get an array of magazine classes that a weapon will accept? I thought

_weaponAcceptedMagazines = getArray (configfile >> "CfgWeapons" >> _weaponName >> "magazines");

was getting my acceptedMagazines but apparently not.

I believe this is a bug as this behaviour is present in vanilla:
whut.jpg

I'd be interested if a staff member could explain this bug, as I assumed all weapons got their accepted mags from their config and yet the arifle_MX_GL_Black_F seems to getting its accepted bags from somewhere else? Where? Spooky!

Share this post


Link to post
Share on other sites

This - https://community.bistudio.com/wiki/BIS_fnc_compatibleMagazines

 

Keep in mind too you've mentioned the GL variant of the MX, but then referenced the SW variant for the rest of the post, if that makes any difference to what you're doing.

 

57 minutes ago, juleshuxley said:

Looking at the arifle_MX_GL_Black_F's config suggests to me it can only take 100Rnd_65x39_caseless_black_mag magazines.


magazines[] = {"30Rnd_65x39_caseless_black_mag"};

 

 

  • Thanks 1

Share this post


Link to post
Share on other sites
1 hour ago, beno_83au said:

horrible post editing skills........

trumpfaces.gif

Thanks that function gets better results, I really need to remember to check the BIS functions

  • Like 1

Share this post


Link to post
Share on other sites

Things changed a while back, cannot remember exactly what version.

You need to look at the weapons muzzles magazineWell entry and then use that under CfgMagazineWells to lookup a list of compatible magazines.

  • Like 1

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×