Oh, how glad I am that ActionScript 2 is dead and buried…
… but unfortunately not in a personal project of mine that I started quite a while ago and which I have resumed work on recently.
Today, I have been finally able to fix a bug which had already taken me some hours to trace down. Basically, mouse-over and -off events would not work properly on certain MovieClip
s. After some digging through my custom code managing these events (which I needed to come up with because there is no way to let hover events bubble up the display hierarchy in ActionScript 2), I found that hitTest()
wouldn’t work properly on these clips.
Now the fun part began. I meticulously checked every aspect of the MovieClip
s for anything special, I even considered that it might have something to do with the fact that they were positioned right behind some TextField
s, which could have triggered some Flash player bugs (given that they are already surrounded by a cloud of weirdness in AS2). Nope, nothing.
It wasn’t until I had already pretty much given up that I noticed that the name of the clips in question contained a period. After I removed it … hitTest()
worked fine – thanks a lot for wasting my time, Adobe! Not only that this really should not happen, at least not without a runtime warning, the fact that you cannot use periods in MovieClip
names is apparently undocumented.
Oh well…