Thursday, September 13, 2012

Create Your Own Game Using Notepad

Now you must be having some knowledge about the Batch Programming after reading my previous post. Using some commands from the Batch Programming we can create some simple and amazing games of our own.

To create your own Batch game, you should follow these easy steps:

  • Decide the story-line of the game: You should draw a sketch of how your game will work. Remember, creating games in Batch script has limitations. You will not be able to create more of a game than a text-based game. It can be a quiz or a scenario game, but you will have only text. As to whether or not you want to have ASCII graphics is up to you, but the game will still be based entirely on text input.
  • Learn the Script and Commands: Batch script is not very hard to learn. You should have some knowledge about some important Batch Codes. Some of them are as follow: 

echoTo display a message on the screen
titleTo give a name to the title bar of the window
colorTo set the color of the background and the text
ping localhost -n 5 >nulTo delay the execution of the following command by 5 seconds [you can change the value]
setTo declare a variable
ifThe if command is used to determine what will happen if a certain event occurs. After the if statement (if [something]), a command follows.
clsTo clear the screen
gotoTo go to the label mentioned [goto Label] and execute the block under the label.
:LabelTo create a label. That is to provide a name/tag to a block of the program. [you can name it anything, even :a].
pauseTo pause the execution and ask the user to press any key to continue.

Download and view the complete list of Batch Commands from:

  • Compiling your Program: You can type your code in notepad and save the file with a .bat extension. 

 Here I will provide scripts of some very famous Batch Games:

  • Cave:
View Script Download
  • Coin Toss:
View Script Download
  • Connect Four:
View Script Download
  • Deal Or No Deal:
View Script Download
  • Hangman Version-1:
View Script Download
  • Hangman Version-2:
View Script Download
  • Minesweeper:
View Script Download
  • Monopoly:
View Script Download
  • Naughts and Crosses Version-1:
View Script Download
  • Naughts and Crosses Version-2:
View Script Download
  • Sudoku Solver:
View Script Download
  • Whack a Mole:
View Script Download

Hope you will like and enjoy all the games. If you have programmed some other games then don't forget to share it here in comments!

See Video Tutorial:



  1. hi. thanks for sharing such interesting post. really was fun trying it out.

    hangman game

  2. pls email me some comands @

  3. If you could please send me a way on how to write in or set up a way for a person to save and then load their save (because my game is going to be rather lengthy) I would highly appreciate it. I can't locate anything about this option.