Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #custom sounds for doom
- #create directories
- mkdir -p sounds/custom
- cd sounds/custom
- #records gun sounds
- padsp sox -r 96k -c 1 -d tmp.wav
- #split sounds
- sox tmp.wav bang.wav silence 1 0.1 1% 1 0.1 1% : newfile : restart
- #remove temp
- rm tmp.wav
- # record other sounds
- echo -n "Enter Sound Name: ";read name
- padsp sox -r 96k -c 1 -d tmp.wav
- #split sounds
- sox tmp.wav $name.wav silence 1 0.1 1% 1 0.1 1% : newfile : restart
- #remove temp
- rm tmp.wav
- #move back up to main folder
- cd ../../
- # create sound config file
- find sounds|while read snd;do [[ -f "$snd" ]] && echo -e "$(echo "$snd"|sed 's|sounds/||g'|cut -d\. -f1)\t$(basename "$snd"|cut -d\. -f1)";done |sort > SNDINFO
- # creat random groups automatially
- cat SNDINFO|awk '{print $2}'|tr -d '[0-9]'|sort -u|while read group
- do
- echo "\$random $group {$(grep $group SNDINFO|awk '{print $1}'|tr "\n" " ")}" >> SNDINFO
- done
- # create random groups Manually
- echo -n "Enter Sound Group: ";read group; echo "\$random $group {$(grep $group SNDINFO|awk '{print $1}'|tr "\n" " ")}" >> SNDINFO
- #extra notes
- $random weapons/pistol {custom/bang001 custom/bang002 custom/bang003 custom/bang004 }
- $random grunt/attack {custom/bang001 custom/bang002 custom/bang003 custom/bang004 }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement