Monday, July 16, 2012


When I go over my old code, I find mistakes at an alarming frequency. The only consolation is that one day, I'll stop writing new code long enough for the bug-catching to catch up. Also, it helps that there are only a handful of Hugo users in the world, so at any given time, only a couple of people might be swimming in the morass of my faulty code.

One of the things I like about roodylib is my system for saving globals over a session. I successfully put in some code so that extensions like beta.h can keep track of things like the "is transcripting on?" global over RESTOREs (and not just RESTARTs). I noticed today that my code didn't keep the reverse from happening- that is, routines that should be only run at the beginning of a game (like CalculateHolding(player) and InitPluralObjects) were also running after every game restore or even undo (if colorlib.h is included). That seemed like a pretty bad idea.

Anyhow, I think I have wrangled that issue pretty well, and I have mostly ironed out the PreParse thing how I want it. Still, one always has to wonder how many big, bad bugs there are still out there. Actually, it's no wonder. I know they're out there.

No comments:

Post a Comment