Page 1 of 1
Changing Shotgun Sound. But how?
Posted: Tue Aug 22, 2017 1:11 pm
by M.Colcko
I think we can all agree that the current shotgun sound (0.15.33) is really dull and has no punch to it whatsoever. So I looked for a mod that changes the sound. But I couldn't find any.
So I decided to look for the sound file and replace that with a proper sound. But I can't find the sound for a shotgun firing. Every other weapons sound (e.g. the maschine pistol firing) is there.
So is it even possible to change this? I really wanna have a more satisfiying feeling when blasting biters full with metal.
Re: Changing Shotgun Sound. But how?
Posted: Tue Aug 22, 2017 1:50 pm
by Bilka
The currently used file is "__base__/sound/pump-shotgun.ogg".
To change it, make your own file, place it into your mod and add the following code to your data.lua (modify the file destination to fit you).
Code: Select all
data.raw.gun.shotgun.attack_parameters.sound.filename = "__you-mod__/shotgun.ogg"
data.raw.gun["combat-shotgun"].attack_parameters.sound.filename = "__you-mod__/shotgun.ogg"
Re: Changing Shotgun Sound. But how?
Posted: Wed Aug 23, 2017 8:49 am
by M.Colcko
I'm having a problem:
When i want to load up Factorio im gettung the error message below.
The data.lua looks like this:
Code: Select all
data.raw.gun.shotgun.attack_parameters.sound.filename = "__shotgunsoundReplacer_0.1.0__/shotgun-fire-reload.ogg"
data.raw.gun["combat-shotgun"].attack_parameters.sound.filename = "__shotgunsoundReplacer_0.1.0__/shotgun-fire-reload.ogg"
This is the directory:
Factorio/mods/shotgunsoundReplacer_0.1.0.zip\shotgunsoundReplacer_0.1.0\data.lua, info.json, shotgun-fire-reload.ogg
Can you help me?
Re: Changing Shotgun Sound. But how?
Posted: Wed Aug 23, 2017 10:17 am
by Bilka
M.Colcko wrote:I'm having a problem:
When i want to load up Factorio im gettung the error message below.
The data.lua looks like this:
Code: Select all
data.raw.gun.shotgun.attack_parameters.sound.filename = "__shotgunsoundReplacer_0.1.0__/shotgun-fire-reload.ogg"
data.raw.gun["combat-shotgun"].attack_parameters.sound.filename = "__shotgunsoundReplacer_0.1.0__/shotgun-fire-reload.ogg"
This is the directory:
Factorio/mods/shotgunsoundReplacer_0.1.0.zip\shotgunsoundReplacer_0.1.0\data.lua, info.json, shotgun-fire-reload.ogg
Can you help me?
Remove the mod version from the file path:
Code: Select all
data.raw.gun.shotgun.attack_parameters.sound.filename = "__shotgunsoundReplacer__/shotgun-fire-reload.ogg"
data.raw.gun["combat-shotgun"].attack_parameters.sound.filename = "__shotgunsoundReplacer__/shotgun-fire-reload.ogg"
Re: Changing Shotgun Sound. But how?
Posted: Wed Aug 23, 2017 2:08 pm
by M.Colcko
Ok. Now i am getting a very diffrent error message saying:
"Audio clip sample "__shotgunsoundReplacer__/sounds/shotgun_fire.ogg" not loaded!"
I have uploaded the mod to the portal so you can check any errors yourself:
https://mods.factorio.com/mods/M.Cocko/ ... ndReplacer
Re: Changing Shotgun Sound. But how?
Posted: Wed Aug 23, 2017 3:29 pm
by Bilka
The error occurs in the sound loading phase, which suggests that your audio file is broken in some way, however VLC is able to play it. I would suggest you to try a different file or to de- and encode the audio again, maybe that will fix it. I was able to load the mod by replacing the sound file with another one from one of my mods, and that worked, so it's definitely a problem with you file.
Re: Changing Shotgun Sound. But how?
Posted: Wed Aug 23, 2017 3:38 pm
by M.Colcko
OK thanks. I will try that. I did just change the file type (retype .mp3 to .ogg) so that sure is the issue.
Re: Changing Shotgun Sound. But how?
Posted: Wed Aug 23, 2017 3:45 pm
by M.Colcko
It works just about perfect now. Thank you very much!