Project Zomboid

Project Zomboid

[B41] Suppressor Fix for Brita's Weapon Pack / Arsenal[26] Gunfighter
39 Comments
W 14 Dec, 2024 @ 2:45am 
感谢up,我这就去排查:ExcitedElica:
Oversights2006_  [author] 13 Dec, 2024 @ 8:57pm 
@小糖Anon 服务器上装了好几个枪械mod吧,跨mod的配件装不上很理所当然。除此之外要是你连同mod里的武器配件都装不上就要考虑排查mod列表了,这种属于是有明显冲突了。另外这俩枪械mod本身就多写了一堆功能实现,和其它同类型mod的兼容度注定不会太高,除了那些只添加物品的
W 13 Dec, 2024 @ 4:47pm 
作者我问一下,联机玩gunfighter武器装不了配件是正常现象吗。还是说是要在配置文件里设置,有点苦恼,bilibili上也没找到教程,没办法只能来留言来求助了:steamfacepalm::sad_seagull:
MasterBait_420 12 Dec, 2024 @ 5:59am 
明白,我試試看,謝謝你
Oversights2006_  [author] 11 Dec, 2024 @ 8:47pm 
@MasterBait_420 根据你的描述来看,更像是你本地客户端内声音文件的问题(他人可以听见,且数值是修改的),而且在我的脚本写法中不可能会出现只有数值修改生效而声音不生效的情况,只能是要么都生效,要么都不生效

在MP中,你遇到的情况,别的玩家也同样会遇到吗?如果别的玩家没有这个问题,那就可以断定是你本地的问题了

如果是你本地的问题,那你有修改过任何这两个枪械包中的文件吗?使用任何来自这两个枪械包的消音器和火器都会出现此情况吗?确保你的mod列表里没有和这两个武器包相关的多余mod,尝试取消后重新订阅这两个武器包(一定要检查清空后才重新订阅)
MasterBait_420 11 Dec, 2024 @ 4:37pm 
你好,
我在MP裡只能聽到正常槍聲,但其他玩家都能聽到我是有消音效果,對一定距離的僵屍也會減少吸引力.
但我總不能每次換新槍也先開槍試試吧,請問有什麼解決方法?
Oversights2006_  [author] 3 Dec, 2024 @ 2:42am 
@AK-15 Don't mind about time too much, we're from all over the world after all.
Just now I updated the patch, and few things need to be referred:
1.GSO use same script from WSE, the difference between them are sound assets, GSO covered more than WSE do, and seems like WSE didn't take care of Aersnal/BWP completely.
2.GSO can be considered as a completion for WSE, although no dependency within them. Step further, on the file side, GSO has few same-name files compare to WSE, which means you can use them together for a full-scale sound cover.
3.GSO/WSE can be independently used, the reason of "only work with WSE" would be obviously from above-mentioned.
4.So, I changed the scope of patch from WSE to GSO/WSE, and thanks for sharing the info.
AK-15 2 Dec, 2024 @ 3:43pm 
Sorry for the long response)
AK-15 2 Dec, 2024 @ 3:42pm 
Good afternoon
1. Yes, only the WSE patch stopped working; the mufflers work correctly.
2. This...is quite strange because GSO sounds only work with WSE, in turn WSE has many bugs in sound, for example the lack of sound in SIX12 auto. But these are, of course, questions for the WSE mod itself.
3.Thank you for your work;)
6. I think everything will be fine, I doubt that Brita will update her weapon pack in the near future
Oversights2006_  [author] 2 Dec, 2024 @ 9:25am 
It won't be hard if just related with the patch, I will update it ASAP when I am free after daytime.
Oversights2006_  [author] 2 Dec, 2024 @ 9:23am 
@AK-15 Okay.
1.What exactly stopped working? The WSE patch or the workaround itself?
2.If you have several mods alter the gun shot sounds, that's a bad idea, I provided the WSE patch because I use WSE only and active the workaround will override the WSE config, the patch itself is just a renameed config and rest parts are same.
3.With mention, I just noticed I made a mistake renaming the patch, that will be fixed quick. Besides, it should be the culprit why you heard default SFX since the patch being overrided by function in the workaround. :P
4.Yeah, don't add Z to workaround, but to the patch, it should be a temporary fix.
5.Before conclude the situation, must reproduce same issue with same enviorment.
6.Also, this workaround is tested in SP only, it should be fine on MP but I won't give support on it.
AK-15 1 Dec, 2024 @ 9:55pm 
Pressing Z doesn't help. Reloading the mods on the server didn't help either.
AK-15 1 Dec, 2024 @ 9:53pm 
Good afternoon, the person who wrote that the mod does not work is right, but not at all. Compatibility with the WSE and Gun Sound Overhaul mods does not work, and if possible, please make an adaptation to GSO; the mod is more diverse in sounds. And if we talk about the work of the mod, then yesterday everything worked today I woke up in the morning and heard the standard sounds from Arsenal 26
Oversights2006_  [author] 1 Dec, 2024 @ 6:58pm 
If you find this workaround still not working till even now, please do a binary search on suspected mods and report the issued mod, I'll do some inspection when I have free time.

如果我这mod更新后还是存在有不生效的情况,可以尝试二分法找那些有嫌疑的mod,如果找到了可以发在评论里,我有时间看看它们怎么个做法会覆盖掉传统的加载顺序
Oversights2006_  [author] 1 Dec, 2024 @ 7:47am 
@=DK=Fourlegion 试着改了几个地方,你再试试看看,还有不生效的问题的话,你把你的mod列表发出来,我空余有时间看看能不能排查
=DK=Fourlegion 1 Dec, 2024 @ 3:04am 
呜呜呜,那岂不是玩不了消音了
Oversights2006_  [author] 1 Dec, 2024 @ 2:38am 
@=DK=Fourlegion 和存档无关,这个就是随游戏加载而加载的,有就加载,没有就不加载。不生效是因为你的mod列表里有脚本的优先级更高,默认情况下读取顺序是按照文件名字母顺序来的(以前玩潜行者时的经验,读取lua就这顺序),所以你会看到我文件名改的是Z_开头

不久前也有人报告过,我看看能不能找到在代码本身上override的做法
=DK=Fourlegion 1 Dec, 2024 @ 2:29am 
是要开新档吗
,装了mod进去还是不行
Oversights2006_  [author] 12 Nov, 2024 @ 7:35am 
@Ryan Gosling, it depends on your end, please read the description carefully, if it doesn't work for sure, then a function in your mod build which overrided the onWeaponEquip event in my provided file, the shortcut is to rename my .lua file, add Z as many as it can, e.g. (ZZZZZZZZZZ_abc.lua), however I'm not guaranteeing it would solve your problem, after all it's a rare case after the mod released for such a long time without someone report not working.
Ryan Gosling 12 Nov, 2024 @ 3:39am 
Mod doesnt work
Oversights2006_  [author] 7 Jul, 2024 @ 8:17am 
For further game update compatibility (build42 e.g.), as long as BWP/Gunfighter were not going modify how the suppressors running, this workaround won't be invalid either. Plus, my passion for the game got faded, so I might not be update this as soon if it really do stopped working in future.
Anyway this workaround is built on the latest version of Gunfighter/BWP, you should notice this.

后续游戏本体更新,这个修复还能用吗?假如开发组会对枪械系统有什么彻底的重做,那么我觉得枪械模组也逃不脱出问题的可能,但总之只要这俩模组的作者不对消音器(或者说枪械效果判定)的代码段做什么改动,那这个修复就不可能存在失效的情况(当然要是他们加了什么莫名奇妙的新判定那另当别论了)
Oversights2006_  [author] 8 Apr, 2024 @ 8:45am 
And as the FAQ mentioned either, the files from this mod will not have any conflict with any other mod, if you were worrying will the patch have compatibility issue, then the answer is no, you can move it to any specific priority that load after BWP/GF/WSE
Oversights2006_  [author] 8 Apr, 2024 @ 8:38am 
@Vanh No no no, I didn't mean that, you don't have to be sorry my mate, I just thought that question is somehow self-evident, in the mod menu you can see that the patch should require you active BWP/GF/WSE at the same time, so that means the load order is definitely done when you active it.
Vanh 8 Apr, 2024 @ 7:06am 
Thanks, english is not my native language, sorry if it sounds rude
Oversights2006_  [author] 8 Apr, 2024 @ 3:22am 
@Vanh well, dude, don't you think that question is a bit of...never mind, just let the WSE Patch after BWP, GF and WSE. order about the main file of my mod is no need to be considered.
Vanh 7 Apr, 2024 @ 2:40am 
what is load order with wse
Oversights2006_  [author] 30 Mar, 2024 @ 1:37am 
@xMonk No, this is an alternative way to make suppressors in Gunfighter/BWP to work if it didn't, this mod doesn't contain any in-game materiel player can have/see/notice, it do its job on code-level, nothing more else.
xMonk 30 Mar, 2024 @ 12:32am 
Need find a magazine?
坚定的党员 24 Mar, 2024 @ 9:30am 
下个试试
Oversights2006_  [author] 24 Mar, 2024 @ 3:02am 
@Zwierzax Sure mate, thanks for your generous words first, and just now I took a look at the ratio of visit/sub, seems like that's a common issue, anyway it's glad this tricky pill was done for, whoop. But you remind me about the sound, it did come with the code either, damn, my perfectionism sick got itching, might look at that later, lol :steamfacepalm:
Zwierzax 24 Mar, 2024 @ 1:20am 
As Phade said - without this mod supps works for me, both "sound" it's phew phew not bang bang. And for zeds hearing radius - from waking up whole neighborhood to maybe 15 - 20 cells away for 9mm.
So either mod options, mod load order or anything else that I don't think right now.
But still, I am amazed that U make mod for yourself to combat this problem :steamhappy:
Oversights2006_  [author] 23 Mar, 2024 @ 1:52am 
@Phade That's strange, perhaps function call conflict with specific mods build? I really don't want to spend more time on this anymore, and good to know that's not a 100% happened situation. I will pin that in description, thanks for feedback.
Phade 22 Mar, 2024 @ 10:15pm 
Suppressors work fine in britas without this mod for me O.o
Oversights2006_  [author] 20 Mar, 2024 @ 9:11pm 
@Lillith Sorry but it that a suppressor? I saw it but in the code it's not perform like a suppressor.
Oversights2006_  [author] 20 Mar, 2024 @ 9:00pm 
FINAL, the whole gun's benefits like grenade launcher, bayonet or etc. will be finally checked and dispatched on the "equipPrimaryItem" event, and that's a function called "APPLY_EFFECT", and a little part of it will calculate the final suppression level for the gun, it's
BaseSoundValue (based on Gun and ammo) * SuppressionFactor (we got in SECOND step) * SuppresionLevel (yes that one in mod option)
. So it should be nice isn't it? If it works, then when we attach a suppressor, the SOUND VOLUME & SOUND RADIUS would be lowered in difference based on what gun & what ammo & what kind of suppressor we using,
BUT in actual game, the volume or radius won't be changed w/ or w/o a suppressor.
So sadly it's not WORKING on code level. Then I made this WORKAROUND instead of a FIX.

IT'S Hell long but it's necessary to tell better why, if the description upon didn't make sense for you.
Oversights2006_  [author] 20 Mar, 2024 @ 9:00pm 
3.
On code level, that's the KEY point
. If you'd like, you can read the code from Gunslinger folder on your own, the functions is located in it. And now I'm telling you why I said the suppressors didn't work. In the code, FIRST, a gun, or rangedWeapon more accurate, it will be inspected to see if it's suppressed , by checking it got a suppressor(integrated or attached), if true then move to next function. SECOND, now we will calculate suppression factor based on what ammo and what kind of suppressor being used, however it missed "suppressor" string on condition judging, I tried to add but not working, maybe some API ref went wrong, that doesn't matter because we are not done yet. So, now we got a value, it could be as lower as if you use more effective muzzle attachment and ammo for smaller caliber.
Oversights2006_  [author] 20 Mar, 2024 @ 8:59pm 
@Zwierzax Thanks for your answer, but I think I need to explain with that:
1. On sound hearing level , sadly no, they didn't work on my end, no difference if I attached a suppressor or not. And I'm pretty sure there is no corrupted file, or file missed when pull down mod from the cloud.

2. On realistic level , I know PZ is tending to be "immersive" by giving so many things to do in the game, those can be felt when I first played it, and that's also why I keep playing it for weeks. BUT, it's still a game after all and Gunslinger/Brita is not THAT focused realistic, because I can use H&K MP7 to fire 9mm para bellum. I am not that serious about how caliber or ammunition correctly work, and if they could perform like in realistic life not that dramatic, then it would be Okay to me, and for me it's a game bring me fun, not a simulation software.
Zwierzax 20 Mar, 2024 @ 4:05pm 
Answer for your afterword:
The suppressors works in brita/gunslinger, but is realistic.
If you ever hear gunshot, and suppressed gunshot, you will know.
And in mod options you can choose "mousefart" option for suppressors if you want.
One can only fully suppress subsonic ammunition that isn't present in game, and is avaiable only in certain callibers like 9mm, 300BLK and few others.
Femboy 20 Mar, 2024 @ 2:22pm 
novritsch suppressor