Jump to content
Croslely

Can I gain item after gun's shot?

Recommended Posts

I wanna gain ammo's cartridges after every guns shot.

 

because brass is not enough...

 

I cant see anywhere about 'shot' or 'gain items' in buffs.xml or any xml..

 

how can I do to make mod about these function

 

plz help me.

Share this post


Link to post
Share on other sites

You should be able to.

In items, for the firearm in question, under action0

<property name="Create_item" value="resourceBulletCasing"/>

Edited by Mihail (see edit history)
  • Like 1

Share this post


Link to post
Share on other sites

Hi Croslely


If you want brass, why don't you install a mod that adds brass or the creation of brass when mixing materials, I use mine, brass is obtained from zinc and copper mixed in the cement mixer and a compound is formed that melts in the forge , there's also the Meancloud mod (I think it's called yes), which adds boulders on the copper and zinc surface.
Regards

Share this post


Link to post
Share on other sites

Also, if you look at the dev comments in item modifications.xml there is specific mention of a brass catcher. 

Share this post


Link to post
Share on other sites

Nice idea. Besides that brass is not really rare since you can melt dukes to brass and easily get lots of dukes by trader quests (and selling stuff), i always wondered why in an apocalypse where ressources are more or less rare deosn't pick up the used bulletcasings. Especially if you melt brass and craft new amunition yourself anyway.

Share this post


Link to post
Share on other sites
15 hours ago, convergent said:

Also, if you look at the dev comments in item modifications.xml there is specific mention of a brass catcher. 

I'm not seeing that in my item_modifiers.xml. Any chance you could paste that into the thread? I literally started working on a brass catching mod this weekend.

I was wrong about adding to the action since firearms don't appear to work that way.
-
Anyone familiar with how onSelfItemLost works? That was my next theoretical approach to this problem.

Share this post


Link to post
Share on other sites

Just tried adding jars as in boiledWatter item.... it doesn't work...

Guess the problem is in the superclass Eat and Drink and it is not inherited by Weapons

<property name="Class" value="Eat"/>

Share this post


Link to post
Share on other sites

I have a lunatic idea:

What if only a trader could open the brass catcher?

That is, could we make a quest that is initialized by firing with the mod attached, that then increments a variable for each shot fired if the quest is active, and whose reward is brass casings in an amount equal to that variable?

Share this post


Link to post
Share on other sites

Another thought on this would be that you don't want it to catch ALL casings.  Maybe 60 percent.  not all casings are re-useable after be fired.  especially if fired multiple times already.  So you need to have way to do that in the game.

 

Share this post


Link to post
Share on other sites
7 hours ago, Iceburg71 said:

Another thought on this would be that you don't want it to catch ALL casings.  Maybe 60 percent.  not all casings are re-useable after be fired.  especially if fired multiple times already.  So you need to have way to do that in the game.

 

yep but you could still melt it...

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...