I’m working on a very large Flash game project, and we’ve run across a problem that is extremely annoying.
Every third (or so) compilation, apparently randomly, CS5 doesn’t embed the entire character set for a certain font into our application. We notice this when certain characters are missing in various places in the game. I can reproduce this problem by recompiling several times; sometimes the font will be embedded, sometimes not.
Has anyone run into a similar issue, and if so, how did you solve it? Any ideas on how to figure out the cause of this problem?
Flash has always had issues with font handling. If font exports behave erratic like that, you probably won’t find the problem either – it needs to be reproducible in some way to recognize a pattern…
However, you can improve your build process and reduce these irregularities to a minimum: You should always keep all fonts in one or more separate FLAs. Export these files into .SWC components, and include those in the class path of your application FLA.
That way you can be sure that none of the other elements in the library affect the exporting behavior, and once the fonts are compiled correctly, the problem will never slow you down again. Also, it will significantly reduce compilation time in general – exporting fonts from the library is a real drag on the compiler, and you wouldn’t want to wait for it every time you change something in your code.