00:00Nothing is new, but what we're going to do right now is build our application from scratch
00:05assuming that we've never downloaded the file.
00:07Now if you're very comfortable with all the videos that we've done so far then you don't
00:10really have to watch this video, but if you feel like having like a little bit more rehearsal
00:14before we actually start programming.
00:16So let's do it.
00:17What we want to do first is let's create a new folder.
00:20I'm going to create a new folder and I'm going to call it my project files.
00:25In my projects file folder I'm going to create two new files, two new folders, sorry.
00:30That will be my deploy and the next item will be my source.
00:36So I have my source and I have my deploy.
00:39Next thing is I want to open up my Flash and I'm working on Flash CS5 and I'm going to create
00:44a new ActionScript 3 file.
00:48Created a new ActionScript 3 file and now I want to save it so I'm going to go to file,
00:53save as.
00:54I'm going to make sure I'm in my source folder in my desktop, project files, source and I'm
01:02going to call it main and I'm going to save it.
01:07Now that I saved my main I want to create, first of all I want to change my publish settings
01:11so I'm going to go to file, publish settings and then in my Flash configuration I'm going
01:18to change it to one folder back, deploy and another slash.
01:24Same thing here, dot, dot, one folder back, deploy, slash and I want to change it from
01:30main to index and I'm going to click OK and I'm going to save my file again, I'm going
01:38to go to my file and I'm going to publish it to just make sure that when we go back
01:43in here that in our deploy we have our main and we have our index.html.
01:49Perfecto.
01:50So back in our main we want to create now our AS file which we are going to store all
01:55of our ActionScript.
01:57So I'm going to go and click on file, new and then I'm going to select an ActionScript
02:023 class.
02:03I'm going to click OK and now because I'm working with Flash CS5 it's going to change
02:13and generate for me some stuff dynamically so I want to call it main my class, I'm
02:18going to click OK and it's going to automatically create a lot of things for me
02:23that I need so I don't have to type them myself but let's assume that it didn't
02:28just for people that are not running on CS5 so I'm just going to delete all
02:33that goodies and let's start typing.
02:36So first of all we're going to create a new package, whoa, package not whatever
02:41I typed.
02:42We're going to open a bracket and we're going to close a bracket.
02:45Flash CS5 automatically is going to do that extra goody of closing the
02:49bracket for me.
02:51I'm going to type now import, space, flash, dot, display, dot, movie, clip.
03:05And now we're going to create a new class so we're going to set up our public
03:14class, we're going to call it main extends movie clip.
03:22Now don't worry about what this all means, it's really just a matter of making
03:26sure that you have all of this for now and whatever we recommend is just to
03:30download the source anyways because until we really understand what it is
03:34it doesn't really mean too much to type it but it's good practice it doesn't
03:38hurt.
03:39The next thing we want to do is we want to create our function public
03:42function.
03:43Main, we want to make sure that the names all match up, upper case M, all
03:47the rest lower case.
03:49And public main, this time around we're going to open a round bracket,
03:52close a round bracket, open a curly bracket and then close a curly
03:56bracket.
03:57And there we go.
03:59We have everything set up.
04:01All that's left is we want to now save the file.
04:03So we're going to click on file, save and we're going to take it in the
04:07same folder, we're going to call it main.as.
04:11And now back to our main FLA, we will want to go into our publish
04:15settings and then in our class set it to be main.
04:19And let's just make sure that it works.
04:21Click on edit class definition and we see their link together.
04:24And just to prove it we're going to put here a little trace in line
04:27six.
04:35So this is basically what we've done in all the past videos only
04:38really quickly.
04:40And it would be really good practice to just get used to typing it.
04:43It does not hurt at all to know how to do it even if we don't
04:46understand all the intricacies or whatever the word is of what's
04:52inside here for now.
04:53And as time goes by, as the course is, as we evolve, as
04:57programmers we completely understand every single line here.
05:02So just run it, see our hello world.
05:05And this is a wrap.