Here's a tip: try
googling for "flash decompiler". There are several tools that will help you view the code of and disect a flash application. It might help to know that the newer flash script (action script) is basically ecma/java-script only with a different environment.
Good luck :)