|
-
Originally posted by Johnny Vasqueles
I would like to know more about making these files. I don't have a problem with morpheus, but how does this file you're making work? How do you make it run, where do you put it, etc? This is a foriegn concept to me.
Batch files?
Batch files are basically just a set of commands for DOS (and later Windows to execute). Back in say the DOS 6.22 days, I had batch files to do lots of stuff. For instance, I had a batch file called "wolf.bat" that would first change the directory to wolf3d (run the command "cd \wolf3d\") and would then run the executable ("wolf3d"). I placed this in a folder called "batch" and put that in the path. This way from anywhere on the machine I could just type "wolf" and play some Wolfenstein. It's simple really. Each line of the file does a DOS command. For instance, if I wanted to make a batch file to delete all the files from the directory c:\temp, I could write something like this:
Code:
c:
cd \temp
del *.*
You see, it changes to the C: drive to make sure you are on the right drive. It then changes the directory to "temp" and deletes all the files there. Note--this could be done in one line (del c:\temp\*.*), but I lengthened it for demonstration purposes.
Anyhow, batch files used to be quite handy. As Windows has evolved, I've used them less and less, but still there are a few different applications where they can be quick and helpful (though I'm beginning to lean more and more towards windows scripting).
EDIT:
Missed a few points about your questions.
First, "how do you make it run?"
Windows/DOS recognizes the .bat extension and parses the file and runs the command therein.
Second, "where do you put it?"
Whereever. If you put it in a directory that isn't in your PATH variable, you will have to be in that directory to run it however. For example, if I created a batch file to run Morpheus (as above), I would probably name it Morpheus.bat and place it in the same directory as the Morpheus executable. I would then make a shortcut in Windows (or change the old Morpheus shortcut) to point to that .bat file.
Anyhow, if you have any other questions, feel free to ask.
Last edited by Nick_B; 02-19-2002 at 03:06 PM.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|