Re: My code is haunted

Apparently nothing gets comments going like boring programming stuff. 😛 Anyways, the exciting conclusion!

You were all wrong. I was wrong. Well, half-wrong After all, the buggy code did rise from the grave and came back to haunt me one month later! Just in time for Halloween.

The _speed variable in question was inherited from MovingTarget. Which would’ve been fine, except there was a leftover _speed variable in Craft too. Uninitialized too, naturally. Just hiding there, no warnings, no anything, just happily confusing me and the compiler. Ain’t programming wonderful? A learning experience every day.

2 thoughts on “Re: My code is haunted

  1. Davorian

    Haha, I at least like to think I was on the right track after mentioning inheritance 🙂

    In any case, it’s good to hear that you tracked the error down!

  2. Martin Stiborsky

    Congratulation to solve this thing!
    More posts like this would be great!
    Whole OpenXCom is really interesting.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

This site uses Akismet to reduce spam. Learn how your comment data is processed.