welcome to the party,

 The basics of design patterns evolved from the timeline for me.

Flash is an 'object oriented language' - that is each symbol is an independent 'thing' in the library.

Learning the time line and how to do a tween came first, oooh, a moving thing on the screen.

Next, we learned how to make a 'stop/start' button. A 'control' for the movement.

Thus two segments of the proverbial 'design pattern - the controller and the content.

Learning how to load another clip into the content makes that section of the pattern a bit more complex, but does not affect the 'controller button' in any way.

Changing the button so it is a slider makes that section of the pattern a bit more complex without changing the content or it's payload, except that now with the control acting as a slider we have more fine grained interaction with the content.

Knowing only Flash, this all seems quit natural, but these types of programming feats are quit difficult in most other programming systems.

Separating what we do to the content from what the content is allows us to - say load different source text into the content object without mangling our control button.

This 'design pattern' also allows us to create another button that adjusts the scale or rotation of the content object while also leaving the original 'on/off' function of the first button undamaged.

That's all there is to it. Of course it can be far more complex. Say we want to change the content loaded into the content object based on a user name, or day of the week... none of the new abilities should mess with the existing controls we already made. And a sequence of decisions must be made before loading any content into the content container - This then calls for a new type of object/function - a load sequencer that acts without damaging the existing working set up.

I am not quit sure of the specific terms of the formal vocabulary, but the idea of keeping different aspects of the project 'compartmentalized' is what design patterns are all about. The separation of the general areas of the project keep us organized and help avoid damaging sections that are working correctly as we add new abilities to any given project.

As projects become more complicated groups of similar types of activities in the program will naturally be in one part of the interaction 'pattern' and that is why everyone says take it easy and don't push too hard to get it all into a predefined 'pattern' too soon because that will make a person crazy... :)

hth,
Dave_Matthews
http://www.2GoTo.com


-----Original Message-----
From: [EMAIL PROTECTED] [mailto:flashcoders-
[EMAIL PROTECTED] On Behalf Of David Bellerive
Sent: Friday, August 18, 2006 9:41 AM
To: [email protected]
Subject: [Flashcoders] Best way to learn OO Analysis and Design with
ActionScript

Hi everyone!

I'm having real difficulty understanding how to
properly architect and structure Flash applications
using ActionScript 2.0.

I've read Colin Moock's excellent "Essential
ActionScript 2.0" and several other books and articles
on the topic and while I can safely say that I do
understand the syntax, I can't seem to write an entire
application using OO design mainly because I can't
figure out what should be in a class, which class
should do what, which class should extend MovieClip,
which class should use composition instead, which
class should start the application, etc.

I'm sure a lot of excellent Flash developpers in this
mailing list didn't have previous coding experience
before they started Flash (like myself) and managed to
become the ActionScript 2.0 OO pros aroud here.

Any help / tips ?

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


------------------------------


_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com

Reply via email to