Project Zomboid

Project Zomboid

Spent Casings for VFE
72 Comments
AltenRoguerz 25 Jul @ 4:48am 
Totally's Historical Firearms Pack Support when???
Sven  [author] 31 May @ 12:54pm 
@Rubber Flubber
Thanks a lot fo the insight, and I didn't know about the renderer switch. :steamthumbsup:

Oh, and the gunplay option is good news; I couldn't stand having a crosshair on screen when aiming, but I do know many others like it the more precis aiming it offers, hence why ATRO was so popular for B41.
Rubber Flubber 31 May @ 10:59am 
Additionally, I think they added an option to use B41's gunplay in B42, but I haven't tried it out because I personally prefer 42's. I think it's under the UI options.
Rubber Flubber 31 May @ 10:58am 
Oh please don't feel bad about this, it's a tricky problem to solve. I don't have much Lua or modelling experience, but I've dabbled a bit with things here and there to get it to at least a functional state with Rain's firearms and I'm happy enough with the results.

I think whenever you do look into it, it'd be worth looking into what's different between the revolver casings (I think it's something like PistolLong?) and the regular pistol casings as even when the revolver ones are scaled down a ton they are still visible whereas the regular ones are invisible in the B42 renderer.

You can also switch back and forth between the B41 and B42 renderer by pressing the Home key on your keyboard, might help with debugging if you didn't know about that one.
Sven  [author] 30 May @ 7:38pm 
I'm sorry for being absent on this. I've been so swamped with other things, and still am, and I haven't had an interest in Zomboid in a while. I will install B42 shortly (I'm currently on B41 because B42 gunplay sucks massive balls for no discernable reason and I'm a gun guy), and fix this mod.

While axis may be a factor, scaling is definitely a factor as well. A lot of unchanged vanilla models have new scale values since B42, and I do believe they indeed changed something here, unfortunately. I just haven't found the time, nor energy, to figure it out, but I will look into it sometime soon. I'm just swamped with work. Anyone who has a solution is welcome to contribute.
Rubber Flubber 29 May @ 10:19pm 
I noticed the same thing as well.

Switching the model those rounds use to the revolver casings and scaling them down also works, but looks a bit wonky just because they're not the right type of casing.

I think it's an issue with the model and/or how it's placed in the world, but I'm not sure how to go about fixing them.
Acheron 21 May @ 5:27pm 
Hi, 9 mm are not invisible, scale has nothing to do with it. The shell appears on the z-axis -0. If you set it to 0.01, it is visible. But how to do this for each new shell?
Rubber Flubber 19 Apr @ 2:40pm 
Just wanted to chime in with an update: I got the casings working with Rain's, thanks again for the help!
Rubber Flubber 20 Mar @ 3:44pm 
I really appreciate the response! Thanks a bunch and I wish you luck in solving the scale issue.

Even if things don't work as they should, what it adds is a still a nice touch over the lack of casings the game has by default.
Sven  [author] 19 Mar @ 12:10am 
But if you really want to, in the meantime, you would need to add the new calibers as WorldItems in the relevant script file, and the case spawning code will recognize the fired caliber automatically and spawn a casing if there's a casing Item defined in the script. For example, make a new item entry, 'item 762x39Bullets_Casing', and copy the info verbatim from '762Bullets_Casing'; '762Bullets' in VFE is the Soviet cartridge, while in Rain's mod, '762Bullets' is the NATO cartridge, so you might wanna shift those models around (StaticModel and WorldStaticModel) to get brass casings for the NATO cartridge and steel casings for the Soviet cartridge. Of course, this bricks VFE compatibility, kind of, since they fight over what the game should do with 'Base.762Bullets'; it's an either or situation when it comes to gun overhaul mods.

[2/2 due to character limit]
Sven  [author] 19 Mar @ 12:10am 
@Rubber Flubber
For B42? No, not yet. The problem with my casing mods currently being stagnant is that B42 changed something in regards to how the scale of 3D models is calculated when placed in the world as WorldItems. In the current B42 version, 9mm casings, for example, are too small to be seen, while .308 casings are too large. It's a mess I haven't gotten to yet. But technically, of course, the mod works with B42, since the mod's code is doing what it's supposed to; the result is just not satisfactory. If you're playing B42, and the B42 version of Rain's mod, you might not find much use in trying to make this mod work with it at the moment.

But just because you brought it up, I'm now motivated to keep looking at the scale issue again. :steamthumbsup:

[1/2 due to character limit]
Rubber Flubber 18 Mar @ 11:51pm 
Can't edit my post, but it appears some of the casings do work like .44 with the Marlin
Rubber Flubber 18 Mar @ 5:41pm 
I see you already responded to someone asking about Rain's firearms, but do you know roughly what would need to be done for someone to modify this mod to work with it?

Would it just be a matter of renaming some things, or would every gun need to be individually modified to work with this? As far as I can tell the only two ammo types it adds are 7.62x39 and 7.62x51, which this one already covers.
SDgamer 23 Feb @ 6:55pm 
are we able to turn spent shells into scrap metal without Ammo Maker? Asking because of the Scrap Guns Add-On for The Workshop mod for B41 which uses Scrap Metal in the recipe unless you are using ammo maker
Aymira 14 Feb @ 11:04am 
@Sven alright o7
Sven  [author] 14 Feb @ 9:01am 
@Aymira
I had planned on making mods for all major gun mods, but B42 dropped, requiring a bunch of rework, and I've been very busy as of late, which has slowed progress. But I absolutely intend to have a Spent Casings for Rain's Firearms sometime in the future.
Sven  [author] 5 Feb @ 2:08am 
For those wondering about the 'invisible casings', I'll just repost my reply from my other mod's comment section:

"I've been doing some testing, and it appears to be a scale issue in B42; basically, the items were too small to be seen. For example, .308 casings appear, but smaller than they should be compared to the B41 version. This will require some time to figure out and correct."

Basically, the 9mm casings ARE there, but the scale and visibility cutoff is completely different in B42 for whatever reason, and I've been very busy IRL, so I haven't had time to figure out the new scale system, and I don't know how long this will take me. I gotta figure out how that works, and then match everything to the original B41 sizes.
rican 4 Feb @ 7:11pm 
9mm casings are invisible cuh :steambored:
Aviticus Dragon 2 Feb @ 6:49am 
This doesn't seem to despawn any casings even after you remove them to the despawn list.
spoono 17 Jan @ 3:27pm 
hi, not sure why, but the 9mm model is invisible on my end. this is my only mod
Nice. Thanks a lot. :jake::steamthumbsup:
Sven  [author] 10 Jan @ 3:38pm 
@Marc
Been on my to-do list forever. I will eventually make spent casing mods for all major gun mods, and also a vanilla standalone so people won't need this one for vanilla-guns-only gameplay. Basically "it's coming up".

@borkie
See above.
borkie :3 9 Jan @ 4:03pm 
Compatibility with Hyzo's "Firearms" mod? Specifically for Build 42?
https://steamhost.cn/steamcommunity_com/sharedfiles/filedetails/?id=2256623447&searchtext=firearm
Dord 9 Jan @ 2:27am 
Thank you very much!
Sven  [author] 8 Jan @ 9:57pm 
It's been updated now. Let me know if there are problems. First time diving into the mess that is backward (or forward, if you prefer) compatibility.
Sven  [author] 8 Jan @ 5:35am 
@Dord
Yes, I've just been extremely busy over the holidays, and haven't gotten to it yet.
Dord 8 Jan @ 4:17am 
will it be for 42? :steambored:
Killa Klappa 22 Dec, 2024 @ 1:03am 
this mod + schiZ's random patches + VFE in combination really adds a more realistic but still lore accurate weapon feel to the game, love it
Sven  [author] 13 Nov, 2024 @ 12:59pm 
@PotatoBullets
Thank you for your comment. I've almost finished an addon mod (to be used alongside e.g. this one) for all Totally's calibers from all his gun mods, so that's on its way. :steamthumbsup:
PotatoBullets 13 Nov, 2024 @ 8:53am 
Cool mod! Would love to see 30-06 from Totally's American Firearms in the future :)
Sven  [author] 6 Oct, 2024 @ 11:17pm 
@SDgamer
Yes, the author of Ammo Maker updated his mod a while back to support this mod. You just reminded me I should update the description of this mod. :steamthumbsup:
SDgamer 6 Oct, 2024 @ 7:35pm 
I take it this works with Ammo Maker then?
Sven  [author] 28 Aug, 2024 @ 3:45am 
@Mlemlom
Thank you for your comment. I'm glad you like it.
ₘₑₗₒₙ🍈 26 Aug, 2024 @ 1:24pm 
This mod is absolutely what I needed, thank you for making and sharing
Sven  [author] 23 Jul, 2024 @ 12:16am 
@Цикута
Always been off my radar, but I'll look into it. :steamthumbsup:
Цикута 22 Jul, 2024 @ 12:29pm 
How about totally Historical firearms?
PersonPerson 28 Jun, 2024 @ 4:45am 
Fuck yeah, a mod that serves aesthetic purposes.
Sven  [author] 15 Jun, 2024 @ 6:39am 
All good then. :steamthumbsup:
Gimbo 15 Jun, 2024 @ 5:53am 
I don't use AFR
Sven  [author] 15 Jun, 2024 @ 4:01am 
@Gimbo
VFE has been updated to fix this issue! Just tested it myself, and it works. Although if you're also using AFR along with VFE, that mod seems to override it, so just disable it to make the VFE double barrel work the way it should.
Gimbo 2 Jun, 2024 @ 6:37am 
ehy i would like to give a feedback the double barrel don't leave any case, i'm using vfe
Sven  [author] 29 May, 2024 @ 1:33pm 
@Vilespring
That would be fantastic! :steamhappy: Especially if it could be applied to all breechloaders.
Sven  [author] 29 May, 2024 @ 1:29pm 
@Sgt. Sarge
It works, yes, but you won't get casings for anything beyond vanilla calibers; as the FAQ states, it works with specific calibers, and not specific mods. However, I've been considering making a separate Firearms B41 version, like I did with Guns of 93, now that it's gotten a revamped version that's quite popular.
Vilespring 29 May, 2024 @ 6:27am 
@Sven I never really thought about thr DB missing that parameter as it never really served any purpose. But I'll look into sneaking it in for VFE's next update making the double barrels work better.
Eshminima 29 May, 2024 @ 1:50am 
Does this work with Firearms B41?
Dr. Berry 26 May, 2024 @ 8:19pm 
Cool, thanks for answering 💜
Sven  [author] 24 May, 2024 @ 9:32am 
@berry
Glad you like the mod!
As for the double barrel, that's intentional. I've disabled casings/shells for all breechloaders, since they'd produce spent casings/shells before reloading, with the double barrel dropping a shell per each shot, even though the character never opened the gun to extract them. Enabling spent shells on reloading would drop shells even when the gun is empty and is being loaded, which would be even worse.
The problem is that the breechloading guns don't have [code]ManuallyRemoveSpentRounds[/code] set to [code]TRUE[/code], so the spent round isn't "stored" in the gun, like with revolvers, so I decided to prevent breechloaders from dropping casings/shells entirely, as a temporary solution.
Dr. Berry 23 May, 2024 @ 1:42pm 
Hope to see this updated!, Real lifesaviour for rp or me and my friends, one of my fav mods. Also.. the double barrel aint ejecting any spents shells..