Thylacine Studios - Forum

Zack, what does your process of finding and fixing bugs look like?  (Read 429 times)

Offline wolfgirl5000

  • **
  • Posts: 73
    • View Profile
poking cocoons in regalis' realm :P

Offline Zack

  • Administrator
  • *****
  • Posts: 3402
    • View Profile
Good question! It's a tough one to answer, but I'll try.

I've been building the same code base since Siralim 1, so I've been working with the same code for about 5 years now. It grows over time as new features are added/removed/changed, but somehow, you start to know exactly where everything is after a while. It's horribly ugly spaghetti code. I'd be embarrassed to show it to anyone. But it becomes a second language when you work with it 60-70 hours per week. You'd be surprised at how your brain manages to organize everything so that when there's a bug, you at least have some idea about where to start looking for issues.

However, probably 70-80% of the bugs/crashes in the game come from mere typos, which is really the biggest drawback to using GameMaker that I've found so far - just about any other IDE in existence wouldn't even allow that to happen.

The biggest problem that I run into now is that a lot of my code was written when I first started using GameMaker, and a lot of it falls victim to some GameMaker-specific nuances that I didn't know existed. For example, I had no idea that you needed to explicitly declare a variable in a script with "var" in order to keep it local to that script - otherwise, you could accidentally use or modify a variable from another script or object instead. I also never took advantage of parent objects, so all the GUI elements are separate objects. That's really bad.
Designer and Programmer of Siralim and The Negative. Follow us on: Facebook | Twitter | YouTube

Offline Cambria

  • *
  • Posts: 16
    • View Profile
I can't even imagine how much code there is to go through in S3. I know there's some things that make it easier to narrow down where the bug is from, but how do you go about figuring out its cause, and fixing it? Are there any design principles you've put into action to make the process easier?

I'm really curious about what it all looks like when you do it - not like screenshots, I code in GML too, I know that part XD. I mean more like, how do you do what you do, and how do you do it so well? And how can I be more like you when I grow up lol?