Archive for Miscellaneous IT

Debugging and Patching Star Trek Armada I – Part 3 of 3

Introduction

In part 1 of this mini-series, we saw how to diagnose and correct the issues preventing an old computer game (Star Trek Armada) from starting on modern (Windows 7) systems. In part 2 we saw how to find the game loop and introduce our own code to slow it down so that the game’s native timing code would work properly.

This third and final post brings closure to the STA reverse engineering by enabling multiplayer saves and presenting a combined diff file for all of the patches we have made in this and the previous posts.

Fix #4 – Enabling Multiplayer Saves

Star Trek Armada is buggy; merely allowing the game to minimize (say, due to a screensaver turning on or alt-tabbing to another program) can cause it to crash. The game also suffers from multiplayer synchronization issues. Ideally, if we could figure out how to save and load multiplayer games, it would allow players in a multiplayer match to continue from a recent point when a problem occurs during gameplay.

Continue reading this entry

Debugging and Patching Star Trek Armada I – Part 2 of 3

Introduction

In part 1 of this mini-series, we saw how it was a relatively simple task to diagnose and correct the issues preventing an old computer game from starting on modern (Windows 7) systems. This post continues the reverse engineering and patching theme to correct additional runtime issues with Star Trek Armada on modern systems.

Fix #3 – Abnormal Simulation Speed

Once the game was starting correctly, it played just fine on my laptop. When I tried it on one of my family’s desktop machines; however, things were a different story.

Continue reading this entry

Installing & Using Rsync on Windows

10-21-2013 Update:  Corrected a few errors in the write-up and fixed the template configuration files.

Introduction

I remotely manage the computers & networks for various family members (parents, siblings, and grandparents).  To this end, I currently have router-to-router VPN links consistently established between home networks at five distinct geographic locations.  (These links are maintained using OpenVPN running on my OpenWrt-based gateway routers.)

As administrator of this geographically-diverse home network, I need to consistently back up my family’s data in case disaster strikes.  While there are many reputable cloud-backup solutions available, I prefer to trust my own skills to manage and protect my (and my family’s) data.

As we all know, a key backup strategy is to have off-site backups.  Fortunately, because my VPN spans multiple geographic locations, the off-site backup problem is easy – provided I can periodically synchronize files between computers at different locations.  Unfortunately, my VPN links are limited to approximately 300 KB/s due to the limited uplink bandwidth.  For me, this is where rsync comes in.

What is Rsync?

Rsync is a tool for *NIX.  From the rsync man page, “rsync … [is] … a fast, versatile, remote (and local) file-copying tool.” For me, attractive capabilities of rsync include:

Continue reading this entry

Debugging and Patching Star Trek Armada I – Part 1 of 3

Making Armada Work On Modern Systems
(a.k.a. A Partial Guide to Ollydbg)

Being a professional in the Computer Science field, I don’t have that much time for video games anymore. As a result, when I choose to play games, I typically prefer to take a trip down memory lane and play something from my childhood. One of my favorite games is Star Trek Armada I. Unfortunately, Star Trek Armada I is rather poorly written (from a reliability standpoint) and generally doesn’t play very well (if at all) on most modern Windows systems. I could switch over to Star Trek Armada II, but I much prefer the original game for various design reasons.

Fortunately, modern IT professionals (and amateurs, in my case) are armed with a swath of debugging and reverse engineering tools, with which we can correct some of Star Trek Armada’s shortcomings. So, without further ado, let’s get started!

Continue reading this entry

Windows VB Script for Batch WMA to MP3 Conversion

A few months back, I was attempting to load my music collection on my iPhone for the first time and was encountering issues.  My situation:

  1. I was running iTunes in a Virtual Machine to avoid all the crapware that iTunes installs.
  2. My music library was a combination (about half and half) of WMA and MP3 files.
  3. My music library was well organized in a folder hierarchy.
  4. The iTunes converter was giving me grief upon importing my music library.  (I seem to recall that due to the use of virtual machine snapshots, iTunes kept getting confused and re-converting certain WMA files that had already been converted by it; furthermore, due to the virtualization, conversion of my music library was taking forever!)

“No problem,” I thought, “I’ll just find a tool to batch-convert my entire music library to MP3 format, which is compatible with iTunes.”  My plan was to run this once on the host and then import the entire (converted) folder into iTunes on the VM.

Continue reading this entry