[I'd probably use Firefox but for a bug that really impacts fullscreen Flash gaming, which is about half of what I use the internet for anyway, apart from YouTube. And if it's not a bug, it's a really bad feature.]
I'm working on making a videogame again, mostly as a learning exercise, but I've run into an issue I thought perhaps you'd have some knowledge about -- HUDs. I've made a HUD box that serves to give information on anything you roll over with the mouse, and gets redrawn dynamically into a different format/layout of text fields to suit the particular object you're looking at. But since the text fields themselves aren't class variables, I can't directly manipulate their contents from the parent object, which has all the relevant information.
I figure I could make the dynamic textfields just dispatch an event to the parent on their creation, allowing the parent to identify and access the text fields, and store them in an array for later use [i.e., updating their contents in real time]. But that seems possibly a bit sloppy -- I like to use event dispatch access workarounds as a last resort. Do you know of a better way to resolve this access problem? Should I just go and make them class variables and have some var clutter for the sake of not having to deal with that messy workaround? :/
EDIT: Hm, maybe I should meet myself halfway here and create a class variable array to put all the dynamically generated textFields in. I just don't want sloppy code.