Jump to content
Sign in to follow this  
RozekPoland

PRIMARY in config.cpp (regarding weapons) ?

Recommended Posts

It's a matter of priority (how often the units may use it). For example, the "strokefist" weapons has a very low priority (that's why it doesn't work on vanilla for AI) :

primary = 1; // very low priority

Share this post


Link to post
Share on other sites

I'm looking for a way to remove weapons' actions from Action List like Reload, Drop etc. Changing primary to 0 or 1 in weapon's config only hides the action of changing weapon but does not hide all actions concering that weapon.

Share this post


Link to post
Share on other sites

To get rid of the "drop" action, use "candrop = false". Maybe you could try "autoreload = true" to get rid of the reload action.

Share this post


Link to post
Share on other sites
Maybe you could try "autoreload = true" to get rid of the reload action.

On a sidenote, this only seems to work for firearms. I tried this for tank cannons, but it didn't work :(

Edited by JdB

Share this post


Link to post
Share on other sites

What's more primary seems not to apply to handguns and NV Goggles (may be more, not tested all).

Share this post


Link to post
Share on other sites
What's more primary seems not to apply to handguns and NV Goggles (may be more, not tested all).

Well that seems clear to me, they're not supposed to go in the primary weapons slot (1), but in 2 and 4096. The only slot types that I know of that it's working for are 1, 2 and 256 (heavy weapons). They're completely different classes with their own animations. A nice trick for addonmakers to make a one shot disposable anti tank weapon like the LAW is to make the rocket ammo the same slot type (4096) as the launcher and have it dropped after one shot via eventhandler. That way it won't take up inventory slot space. Found that out when making my own realism mod (the first play test was a real blast, litterally as the Ai was often accused of cheating, well now it was really an unfair fight :D)

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
Sign in to follow this  

×