Wednesday, April 29, 2009

Under The Hood: Building S.E.D.S. 2.0 (Part 1)

While I begin work on some new functionality for the Source Engine Demo Saver, I thought I'd take a bit of time to explain how it came to be, how it works, and where I intend to make improvements and additions from here.  The year was 1967; the place, Arizona- wait, wrong story...

Part 1 - The TF2 Demo Saver and Growing Pains

The Source Engine Demo Saver originated from two problems, both ultimately related to my enjoyment with making gameplay videos.  The first was that it was annoying to have to remember what I named demos to prevent overwriting them; the second was that my clanmates weren't saving demos, and I wanted multiple perspectives for video making.  Even if I convinced them to save demos, it was tricky for me to sort them out since everyone named and sorted them differently.





The first iteration was the TF2 Demo Saver, a proof of concept Batch File program and autoexec.cfg file.  It was functional, but barely and very unintuitive.  Version 1.0 had ten keybinds for recording (1-9 and 0 on the Numpad) and was only capable of backing up those explicit files, so a new demo had to be started every map.

I quickly found this setup to be cumbersome and inelegant, so I set out to make improvements.  Trial and error and a good dose of Google filled in the gaps of my knowledge on batch files and coding and in a week of updates, changes, and whole segments of recoding, I had built the TF2 Demo Saver into a new beast, the Source Engine Demo Saver V1.5:

Version 1.5 had a vast amount of improvements over prior versions.  The first was an Installer Batch File to simplify setup, as my presence was often almost required to help figure out how to get it ready to use before this point.  Another addition was a detailed Readme file, which had been included in some prior versions as well.  Left 4 Dead was added as a Supported Game in Version 1.4, an easy task once the code was in place.    Instead of an autoexec.cfg file, S.E.D.S. now had a dedicated cfg file for itself, and added a call to the autoexec.cfg; and keybinds 1-9 and 0 were replaced with an alias setup using only the numpad Enter key.  It even let users set a directory for S.E.D.S. to look for Steam that wasn't one of the default install paths.

I was very pleased with 1.5; it worked well, was easy enough to use and setup, and seemed to work.  Once I completed 1.5 I encountered a problem though.  Batch files are limited in flexibility, and there's only so much you can do.  If there was a problem in the coding, batch files weren't throwing much of an exception to go by, so it was a lot of scouring for the problem.  Finally, it lacked in appearance.  Certain I could do more with the program and interested in learning some programming, I looked around.  Visual Basic looked interesting.  I had done some C++ back in High School, but most of it was forgotten to me and C++ looked daunting now.  I had heard of C# before, and decided to see what all the hullabaloo was about with some Visual C#...

Continued in Part 2 -S.E.D.S. + C# in 10 Days or Less

Tuesday, April 28, 2009

The Source Engine Demo Saver Version 2.0

What is the Source Engine Demo Saver?

The Source Engine Demo Saver (or S.E.D.S. for short) is a small program to help users record, save, rename, and sort Source game demo recordings (.DEM). By simplifying the process of saving demo files, the Source Engine Demo Saver makes it easy to create Source game demos while minimizing the risk of overwriting older demo files.

Current Version: 2.0 (Updated April 24, 2009).

Currently Supported Games:

  • Team Fortress 2
  • Left 4 Dead
  • Garry's Mod

Download Links:

S.E.D.S. can be downloaded from multiple locations:

FPSBanana

L4DMods



Instructions

Installation

When you first start the Source Engine Demo Saver, the Setup menu will appear automatically. First, enter your Steam Account Name into the text box. If you're unsure of your Steam Account Name, you can check it by opening Steam and selecting File > Settings, then click on the Account tab. Second, select all the games you want to use with S.E.D.S. Verify the information you have entered and selected is correct, then click on "Install Now" to install S.E.D.S.

Once installation has completed, the "Installation completed." message box will appear. Click "OK" to close the program.

Installation Instructions can be found inside the Help Contents (sedsHelp.chm) under "Introduction" > "Installing the Source Engine Demo Saver".


Recording & Saving

Recording demos with S.E.D.S. is only a keystroke away. Simply start a game with S.E.D.S. installed, join a server, and then press the NUMPAD_ENTER key to begin recording your first demo. A message will appear in chat telling you which demo file is being recorded to. If you want to start a new demo recording, you simply press the NUMPAD_ENTER key again to automatically begin a new demo. The Source Engine automatically makes a new demo each time a map changes, but not when you switch servers, so be sure to start a new demo recording for each server you join.

After you exit the game, simply run the Source Engine Demo Saver, check the boxes for the games you want to use the S.E.D.S. to save, and click on the "Save Demos" button. Your demos have now been saved to a "saved_demos'date'" folder in the game directory.

Recording & Saving Instructions can be found inside the Help Contents (sedsHelp.chm) under "Tutorials" > "Recording and Saving My First Demo".

Feedback

If you have any suggestions, questions, or encounter any bugs, please let me know right away. Post here, or send me an email at sedsfeedback@gmail.com. Additional features are planned to be added in the future, so be sure to check back.