Help need to create a BATCHFILE or CMD Script!

  paulgeaf 17:54 26 Feb 07
Locked

Many games have sound and you cannot disable it. I play radio through my PC and sometimes I want to do that and put my kid on to play a game. So I came up woith the obvious simple idea of a bat file that (if it is the type of game with easy to find audio files!) I make for the game in question...something like this:

First I have to use a file lister like DIR list, to list every file in the games AUDIO directory.

When I get the list I then edit it so that it only contains the audio file names.

Now I add a blank.wav file to the audio directory and enter something like the following into the .BAT file:


@ECHO OFFCOPY blank.wav ATARI.wavCOPY blank.wav Extra_Hit.wavCOPY blank.wav Extra_Life_Blob.wavCOPY blank.wav Extra_Start.wavCOPY blank.wav Hit_Paper.wavCOPY blank.wav Hit_Stone_Kuppel.wavCOPY blank.wav Hit_Stone_Metal.wavCOPY blank.wav Hit_Stone_Stone.wavCOPY blank.wav Hit_Stone_Wood.wavCOPY blank.wav Hit_Wood_Dome.wavCOPY blank.wav Hit_Wood_Metal.wavCOPY blank.wav Hit_Wood_Stone.wav

etc...you get the idea right?

Oops I forgot to mention, obviously before I do anything I copy all the original game audiofiles to another place to keep them!

So basically the audio wavs or mp3 or whatever can be replaced by a small blank version and the game will run fine with no sounds anywhere. Then I can sit and listen to my radio while the game plays.


What I want is to learn how I can have a batch file that is a bit more intelligent because it can take hours to copy and name and edit the files for a game with loads of seperate files!

Is there any way to have a batchfile that does this:

I want to be able to place the Bat script into the audio directory (of ANY game audio files directory). Along with the Blank.wav. The script is then run. It copies all of the original soundfiles to a backup subdirectory and then it proceeds to replace every one of them in the main audio directory with a blank version of itself.
the reason I ant it so automated is so that I can use the same Bat script file every time I wish to do this instead of having to create a huge text file with lists of filenames and then edit it for hours etc!

I know it can't be too difficult but I just don't know how I could do it.

This thread is now locked and can not be replied to.

Sniper Elite 4 review: Headshotting Nazis has never felt so good

1995-2015: How technology has changed the world in 20 years

The Best Design, Illustration, Animation and VFX Awards of 2017

WWDC 2017 dates: How to get WWDC 2017 tickets, when is WWDC 2017 and more details announced