Project Zomboid

Project Zomboid

TwoSix M41A Pulse Rifle (With Sound!)
49 kommentarer
Nico 8. feb. kl. 10:42 
we love this weapon, pls pls pls, update it for B42 plssss
Nico 25. dec. 2024 kl. 8:49 
update to b42 pls !!! :P
Nico 23. dec. 2024 kl. 17:49 
update pls !!!
NicyRaider 21. dec. 2024 kl. 7:32 
please update this gem of a mod for build42! its my fav. weapon and would love to play on with my best gun ever. :steamhappy:
nomadthefox12 7. sep. 2024 kl. 13:26 
can you add this to it's own Start With menu? would appreciate it
Yes1555 1. aug. 2024 kl. 3:33 
Where the fuck can I find Xenomorphs in Knox country!?!??!?!?!?!?!
Kaldari 18. feb. 2024 kl. 10:36 
Very nice weapon, but a melee hit with the rifle plays the gunfire sound.
Would it be possible to reduce the sound so that a single shot sounds more like a single shot, rather than a short burst?
On a side note, Cheat Menu Rebirth breaks gun sounds when ghost mode is enabled, as the guns are still silent when ghost mode is disabled
Two-Six  [ophavsmand] 9. okt. 2023 kl. 23:50 
it has sound...
ANIMUS 9. okt. 2023 kl. 20:49 
this is a great mod, id recommend a minor but critical tweak which is the sound! search online for a sound of pulse rifle,
GrimReaper85 30. juni 2023 kl. 3:36 
my brother thinks its just a god weapon. id expect nothing less ha.
GrimReaper85 30. juni 2023 kl. 3:34 
First MOD i put on zomboid. Love the pulse rifle. never had any issues while using gunfighter or britta. this mod always gets priority ;)
Doc Morbid 6. mar. 2023 kl. 5:53 
I would really like to see this weapon in play myself, and compatible with other mods, but there's too much in the other mods and I'm in the middle of a big building play through, so I can't just start taking mods out entirely, especially large ones.
Doc Morbid 6. mar. 2023 kl. 5:50 
I think what Gunfighter itself or maybe the Brita Weapon Pack does to add new ammunition types, as an example, is to create an entirely new file for ammo types and then direct the vanilla code to look at both rather than adding to the original. Perhaps it would be possible to have a separate rate of fire code or file for the pulse rifle and tell the vanilla coding that it has to look at both, and the one weapon uses the new code? I think that's what Gunfighter actually does to modify the rate of fire for the weapons that use modified rates, and leaves the original code in place so that it can be used for standard weapons, which still exist.
Two-Six  [ophavsmand] 5. mar. 2023 kl. 15:27 
Using Gunfighter messes up the way the M41A fires. To get it to burst fire and sync the sounds correctly, I had to change how the rate of fire is calculated. IIRC Gunfighter changes this for its own uses, so they conflict. I'm sure that I could work around it, but that would involve reverse engineering GFs code so I can implement my own within it's confines. As it stands right now, I'm not really up for doing that. Maybe, MAYBE, I will have a stab at it in the future, but who knows? As a supporter of open source and Creative Commons, I'm more than willing to let someone use my code, models, sounds etc, so they can create a separate mod that works with GF as long as they attribute my original work. Just gimme a heads up, lol
Doc Morbid 5. mar. 2023 kl. 15:16 
I would speculate that if you have Brita/Gunfighter, you just can't throw a bunch of weapon mods on this (lacks non-vanilla rails and stuff from that). The way to test would be to start a new save, have both this and Gunfighter, if the game crashes or something really unusable happens, pick your favorite, dump the other one. If you load it up and a lot of stuff doesn't work, same thing. If it's JUST that you can't put mods from Gunfighter, or something minor like that, maybe using both isn't a problem, you just don't get to throw some kind of 2015 rifle scope on it and dump ammo into stuff half a map away... not the worst thing that can happen to you.

TL;DR, if you test on a new save, you can find out what the issues are with Gunfighter yourself without messing up something you're already doing. It won't destroy the whole game, I promise. Unsubscribe to whatever you don't like or doesn't work together.
R.4.V.3.N 5. mar. 2023 kl. 5:44 
Ooohhoho~. M41A Baby~.

Now all we need is a full on UACM/USCM Mode and a Xenomorphs Overhaul to replace all the zombies with buggers. Al La Aliens: Earth War
Archadies Leafwalker 4. mar. 2023 kl. 8:49 
@Two-Six What kind of problems come up when you run this mod with Gunfighter? I would love to use this weapon, but I use Gunfighter so I don't want my game to crash. lol.
Phistandantilus 20. jan. 2023 kl. 22:10 
bro, I didn't even realize you did all this just a few days after I commented on your other Pulse Rifle mod saying "man it'd be cool if you did [exactly this]", and I'm and freakin' thrilled to see this as I've gotten back into zomboid again this month. can't wait to go blasting zombies with this iconic sci-fi gun! huge thanks and great respect to you, Two-Six!

hey, as a total side note, you think anybody is gonna do an Aliens mod and make the zombies into xenomorphs? I mean, might as well complete the ensemble, right? lol. though I guess some space marine cosplay armor would probably be in order first, huh?
Byro 9. dec. 2022 kl. 19:16 
awesome mod love the iconic sound 95 rnd mag , but i would really like to put attatchments on it from Arsenal 26 & Britta Weapons that would make this mod even more awesome
Sasquatch 26. okt. 2022 kl. 0:21 
@Cerberus it uses .45 ACP
Cerberus 12. okt. 2022 kl. 5:29 
whats the ammo it uses? 5.56?
Sasquatch 10. okt. 2022 kl. 15:16 
I deleted my last comment, I got it to work, It does not work on current worlds, you need to make a new one for it to spawn and for those with sounds issues. I did that and everything is working as it should now.
amargen 3. okt. 2022 kl. 20:23 
does this work at all? I can't find this weapon anywhere.
seanpook 25. aug. 2022 kl. 19:33 
I can't get any sounds, is it because I have Vanilla Firearms Expansion?
Node 712 25. aug. 2022 kl. 18:11 
UPDATE IT PLEASE
solarchos 25. aug. 2022 kl. 8:26 
Game over, man! This is game over!!!!
Giant.Scheming.Iron.HOMIE 19. aug. 2022 kl. 16:57 
thx for the mod! I'd like to ask if this is repairable?
CrocBoy172 7. aug. 2022 kl. 4:16 
oh my fucking god thank you XD
Blitz 3. aug. 2022 kl. 16:06 
for some reason my weapon is stuck to singlefire. is there a way to fix this?
NicyRaider 25. juli 2022 kl. 11:46 
such a F***** good mod! i love it! its my fav. gun and i need nothing more..never ever!:cubewink:
DevilKat 24. juli 2022 kl. 22:10 
@Rose We were just saying this as well after seeing the pulse rifle mod!
(Just saw the Barotrauma xenomorph mod - gonna have to give that one a try)
Two-Six  [ophavsmand] 24. juli 2022 kl. 1:31 
@CarltonBob Thanks for your opinion bro
CarltonBob 23. juli 2022 kl. 12:55 
awful gun sound, so abrupt with the cutting in and out when burst firing
TtequillaaBr 20. juli 2022 kl. 18:34 
omg omg nice nice nice
R.4.V.3.N 20. juli 2022 kl. 12:55 
Curious, is there a mod that turns the zombies into Xenomorphs and the "Infection spreads via facehuggers" being worked on by anyone? That'd be amazing to have an "Aliens: Earth War" server set up. (Great comic btw)
Two-Six  [ophavsmand] 18. juli 2022 kl. 5:33 
@StoneCold well yea, but you really want a whole extra set of ammunition for just one gun? Makes no sense particularly. And considering how long it took to get the sound right, I honestly could not be fucked
Scarnie ? 18. juli 2022 kl. 5:26 
Pretty cool! Only one issue - the M41A uses caseless ammunition but there is the sound of brass hitting the floor.
𒅌 18. juli 2022 kl. 0:05 
▬▬▬▬▬▬▬▬▬ஜ۩☆۩ஜ▬▬▬▬▬▬▬▬▬▬
☆★☆ 𝐌𝐂𝐀𝐅𝐅𝐄𝐄 𝐃𝐈𝐃𝐍'𝐓 𝐊𝐈𝐋𝐋 𝐇𝐈𝐌𝐒𝐄𝐋𝐅 ☆★☆
▬▬▬▬▬▬▬▬▬ஜ۩☆۩ஜ▬▬▬▬▬▬▬▬▬▬
give me -rep because im toxic af :3333333
Two-Six  [ophavsmand] 17. juli 2022 kl. 0:23 
@Switchblade Perfect man, glad it's ok. Will probably end up using it in my main game too, lol
西崎 16. juli 2022 kl. 21:41 
They're coming outta the goddamn walls!
[U.N.] Switchblade 16. juli 2022 kl. 16:44 
Worked like a charm. Sound works as intended.

Formatted the function like this (went for my gut):
https://i.imgur.com/HAtjMou.png
Two-Six  [ophavsmand] 16. juli 2022 kl. 14:52 
Looks like you will have to format it as steam has stripped the tabs, Just indent If statement contents etc, hopefully you know what you're doing :)
Two-Six  [ophavsmand] 16. juli 2022 kl. 14:51 
[code]

function bypassM41()
local player = getSpecificPlayer(0)
local weapon = nil
if player ~= nil then
weapon = player:getPrimaryHandItem()
if weapon == nil then return end
end
if player:getModData().hasM41 == nil then
player:getModData().hasM41 = false
end
if weapon:getScriptItem():getName() == "TS_M41ARR" then
Events.OnPlayerUpdate.Remove(ApplyRecoil)
Events.OnWeaponSwing.Remove(SendHit)
Events.OnPlayerUpdate.Remove(WeaponStatus)
Events.OnPlayerUpdate.Remove(AutoTransform)
weapon:setSwingSound("")
player:getModData().hasM41 = true

elseif player:getModData().hasM41 and weapon:getScriptItem():getName() ~= "TS_M41ARR" then
Events.OnPlayerUpdate.Add(ApplyRecoil)
Events.OnWeaponSwing.Add(SendHit)
Events.OnPlayerUpdate.Add(WeaponStatus)
Events.OnPlayerUpdate.Add(AutoTransform)
player:getModData().hasM41 = false
end
end

Events.OnPlayerUpdate.Add(bypassM41)

[/code]
Two-Six  [ophavsmand] 16. juli 2022 kl. 14:50 
Ok, I have written up a function you can chuck in a local copy. it seems to work fine, although I only tested it for a few mins, so you'll have to just give it a try. Bassically when you have the M41 in your hand, it disables a lot of the Gunfighter mod.

Go into the file ARSENAL-26-GunFighter\media\lua\client\GunFighter_02Function.lua. Go to line number 3298 (Just above the Events lines) and add the following code (DISCLAIMER This is my code, none of it is from the Gunfighter mod, only the function names requiring bypassing.)
[U.N.] Switchblade 16. juli 2022 kl. 13:24 
Sounds good to me. The M41A uses caseless 10x24mm ammunition.

I'm already happy if sound gets fixed. If you have any hint on how to fix it in Brita's mod, I'd appreciate it and would integrate it into my local copy.

Thanks in advance for looking at this. =)
Two-Six  [ophavsmand] 16. juli 2022 kl. 9:27 
Alright, so had a poke, and I don't know what the Brita mod code is doing, but it seems to be overiding most of the games original gun, and also any other added gun. It's not only playing 45 shot sounds with the pulse rifles, it's also limiting the bursts from 5 to 3 and cutting the sound short. I created some custom ammo for it to test, and while that sorts the sound, it doesn't fix the bursts, and makes Britas mod go a bit weird as it can't identify the ammo. I will continue to see if I can find a way around it, but tbh, if Britas mod had an exception for other guns than it's own, it would be fine, and I can't go changing their code unfortunately
Two-Six  [ophavsmand] 16. juli 2022 kl. 8:00 
@Switchblade, thats an interesting one. I use britas pack too, so will look into it man. It's interesting as I have completely bypassed theguns sound system for thew rifle, however I think britas does too and uses the ammo to trigger sound rather than the gun, so that would probably be the issue. I thought about making custom ammo for it, but that would make it more of a pain to use. I will see what I can do though bud
[U.N.] Switchblade 16. juli 2022 kl. 7:51 
Badass! Great mod!

I'm having one issue though and I'm pretty sure it's not this mods fault. When I shoot, I can hear two gun sounds. One of this mod and the other is some kind of normal pistol shot.

The mods I use are Brita's Weapon Pack and the Arsenal Mod. Seems there is something colliding. If anybody has an idea, I'm grateful. Otherwise I'm going to try figure it out.
Jman 15. juli 2022 kl. 11:44 
AWESOME !!!!!!!!! thank you!