Programmer’s Notepad: Using the Built in Logger

Many times when scripting a game, the core game engine will output errors,warnings, and other general information to some log file. When scripting, it is usually very helpful to constantly check the log file to ensure that your scripts are working in a proper manner. Programmer’s Notepad gives us the ability to configure its Output panel to pipe in info from a system command.

Some of you may be familiar with the unix command “tail”. Tail allows someone to see that last 10 lines or so of a file. It is a perfect little program for us to use to let us see the log being updated. Most Unix and Linux distros come with the tail command by default. For Windows, you will need to surf the net for a Windows based tail command. Another option for Windows is to download the Cygwin package. Cygwin is a linux simulator for windows and is generally a good idea to have installed for windows developers. You can download it at

Assuming you have installed tail, fire open Programmer’s Notepad. Goto Tools->Options.

Next we need to add a new Ouput program. Select the “Tools” category in the left hand pane.

Now we will tell Programmer’s Notepad, with respect to the logger, what command to execute along with its parameters.

The “Log Preview” is the name of our new tool. You can call it anything you like as it will appear in the Tools menu when we are done. The “-f” tails “Tail” to follow or show us the latest additions to our log file. The “log.txt” is the file we want the logger to pipe out. Click “OK” to proceed.

Now it is time to enjoy the logger. Again, click on “Tools” and then you should see your “Log Preview” option. Select the “Log Preview” option, or whatever you called it when we made the tool, and then an output window should pop up to your delight. From now you can trace log messages in real time while writing your scripts making your life easier and more enjoyable!

Did you find this article useful?

View Results

Loading ... Loading ...

Leave a Reply

You must be logged in to post a comment.