The Basic Context for Programming in Flash - Flash

With the new Actions Panel in Flash 5, you can program interactivity in two ways: by using a drag’n’drop menu-based set of actions (Normal Mode), or by writing interactive commands directly into the Actions list pane of the Actions Panel (Expert Mode).

Normal Mode
This mode consists primarily of attaching actions to keyframes and buttons, and selecting parameters for those commands from drop-down menus (or Action booklets) and/or entering parameters by hand into option fields. Although this method of programming can feel unnatural to traditional programmers, the resulting ActionScript looks and reads the same as the code produced with Expert Mode.

Expert Mode
In Expert Mode, you can type your code from scratch, as well as insert your code with the help of Action booklets. Syntactically, ActionScript looks and feels very much like JavaScript. Macromedia has gone to great lengths to make ActionScript compatible with ECMA-262 (the standard programming guidelines derived from JavaScript). And like other object-oriented languages, ActionScript is composed of many familiar building blocks: variables, operators, conditionals, loops, expressions, built-in properties, subroutines, and native functions.

Accessing ActionScript commands
All of the ActionScript commands are found easily in the Flash interface in the Action booklets or plus (+) button menu in the Actions Panel. However, the assembly of actions with one another is not something Flash automatically performs. Although it is beyond the scope of this to fully explain fundamental programming principles, we can give a sense of the whole of ActionScript by providing you with an organized reference to each of its parts.

Actions list organization in the Actions Panel
In Normal Mode, you can add a line of code below any existing statement by highlighting the existing statement in the Actions list, and then adding your action. If you accidentally add your code in the wrong place, or if you want to move code around, simply select the lines that you want to move and drag them with the mouse. You can also cut, copy, and paste code within the Actions list or from one list to another using Ctrl+X (Command+X), Ctrl+C (Command+C), and Ctrl+V (Command+V), respectively.

In Expert Mode, the highlighting mechanism for selected actions changes. You are free to select partial or entire lines of code, and modify the code in any way you want. With Flash 5, you can even edit your code in your preferred text editor! If you want to create your own programming macros in other programming applications, then you can write your scripts outside of Flash and copy the final code into the Actions Panel when you’re done.

All rights reserved © 2018 Wisdom IT Services India Pvt. Ltd Protection Status

Flash Topics