0

I would like to learn a bit about using actionscript. I currently know zero about flash and such, so I kind of want to learn a bit so I am not so lost when it comes to this subject. Could someone post some really simple tutorials on how to get started.

Please include:

  • Development environment needed (IDE, and such)

Something as simple as a Hello World would be fine. At this moment I don't even know the difference between Actionscript and flash.

chobo
  • 31,561
  • 38
  • 123
  • 191

4 Answers4

5
  1. Get yourself a copy of FlashDevelop
  2. Create a new project
  3. Select from the dialog "AS3 Project"
  4. Open the Main.as file
  5. Save the below
  6. Hit F5 to Test Movie, your first Hello World

    package {
        import flash.display.Sprite;
        import flash.events.Event;
        import flash.text.TextField;
    
        public class Main extends Sprite 
        {
            public function Main():void 
            {
                if (stage) init();
                else addEventListener(Event.ADDED_TO_STAGE, init);
            }
            private function init(e:Event = null):void 
            {
                removeEventListener(Event.ADDED_TO_STAGE, init);
                var txt:TextField = new TextField();
                txt.text = "Hello World";
                addChild(txt);
            }
        }
     }
    
John Giotta
  • 16,432
  • 7
  • 52
  • 82
  • 1
    @John Is Flash and Flex same? – Alpine Mar 07 '11 at 18:46
  • Depends on the context, for the player, yes, they all generate .swf, but the way you make them is different. –  Mar 07 '11 at 18:49
  • 1
    Not really. With Flex you'll mostly use MXML (a language). Flash is the software. Flex and Flash both use ActionScript 3. – John Giotta Mar 07 '11 at 18:52
  • Flex is a framework built on top of what's already available in the Flash player. It's an extra set of functionality and components, and it may or may not be appropriate for your project. The flex compiler, on the other hand, doesn't require you to use those framework components... it's just a way to compile Actionscript without requiring you to use or purchase the Flash IDE or FlashBuilder. – scriptocalypse Mar 07 '11 at 18:55
  • @scriptocalypse For getting started with ActionScript what is better/easier Flex or Flash? – Alpine Mar 07 '11 at 19:08
  • @Alpine It depends on whether you're more of a developer or more of a designer. I'd say that the Flash IDE is easier for most people, but I know a number of developers get tripped up by it. This is why I ask what you intend to do and why you are interested in using Flash for it. – scriptocalypse Mar 07 '11 at 19:32
  • I think I finally get the differences between flex, flash, as3, flash develop. Thanks for the simple program. – chobo Mar 07 '11 at 20:40
  • note that you don't have to code in MXML to use Flex with your AS3 projects. – Chunky Chunk Mar 08 '11 at 16:30
1

GotoAndLearn.com is the BEST place to start with Flash/ActionScript. Go back to some of the older videos. There are a lot of basics covered. Some probably have a little bit of outdated info because Flash has come a long way, but it will give you some good history :)

Also it is probably good to know a bit of the background, of how we got to where we are. So the Adobe Flash page on Wikipedia is probably pretty good for that.

Here are a few other good references:

Community
  • 1
  • 1
Adam Harte
  • 10,369
  • 7
  • 52
  • 85
0

First, you should understand the concept of the display list. To start writing your own piece of code, I highly recommend FlashDevelop. It's a rich-featured IDE (MIT License). But don't cold-shoulder the Adobe Flash IDE. It is good to know the difference of a programmer IDE (FlashDevelop) and designer IDE. When you feel comfortable with the basics, this blog about AS3 design patterns gives you great input.

Matthias
  • 7,432
  • 6
  • 55
  • 88
-1

Take a look at Flash and ActionScript Tutorials

It covers almost everything

  • Animation
  • Drawing and Design
  • Common Tasks
  • ActionScript 3 Basics
  • Using External Data
  • Sound
  • Special Effects
  • Game Development
Alpine
  • 3,838
  • 1
  • 25
  • 18