I am trying to code a program called "FIGHT!.bat", and I want to make it so that you need to keep the title the same as you downloaded it, otherwise an error message would pop up. But I can't do what I want to do. Here is the code so far:
@echo off
if not exist FIGHT!.bat (
cls
echo Sorry, but an error has occured.
echo Redownloading the program or renaming the program can help.
pause
exit
) else (
goto logo
)
:logo
...
This is alright, but if another Batch file is called that, then the game itself can be run with a different title, and I don't want that. Is there any way to check the name of the program so that if the name isn't "FIGHT!.bat", do this?
Thanks.
Aucun commentaire:
Enregistrer un commentaire