29
Gamer Clause is Coming to Town Animation
This is a little animation I did for all the gamers out there for Christmas this year. It’s a few days late…but aye…better late than never.
Mad props to Mafialligator for putting together and giving away such a great chiptune track Another Very 8-Bit Christmas rocks!
Anyways, lemme know what you think. Definitely open to suggestions and criticisms. Hopefully the next one will be much more professional and timely. If you have any requests or ideas, drop me a line in the comments below.
P.S. Major props to anybody who can name all of the characters in it.
P.P.S. Special shouts outs to a few gamers in particular…Robby1051, @videogamegirl, @guysgirl, Rich Rosado (your kindness at E3 inspired this), Raheem/Random/MegaRan (honestly debated putting Megaran in this….maybe next time), and all the kids in my classes this year (Ivonne, Klara, Justin, Jason, Sean, Kyle, Deb, Nina, Andrew, Breaker, Toni, Kareem,etc. .) You guys inspire me to stay on top of my game.
16
Flash AS3 Contact Form
For those of you new to Flash who just want to knock out an AS3 contact form…here you go!
Once you download the file, you’ll notice you can use either 1) normal text fields or 2) UI components from the components panel.
There’s also ton of additional methods, properties, and event handlers commented within the file.
Lastly the code you’ll need for the php file, is commented within the file itself. Use that code to create a file called “mail.php” and 1) remember to enter in the email address you want the form to go to and 2) remember where you upload it!
If you have any questions, hit me up in the comments below. Otherwise, download and enjoy!
1
Flash Lesson 3: Event Handlers and buttons
You want to make a button in flash using AS3? It’s easy!
1)MAKE SURE you’re movie clip has an instance name!

Also, please please please make sure you’re dealing with an actual “movie clip” and not a “button”.
The next step is to go to the Actionscript layer (you should have a layer label “actionscipt”, “as”, or something of that nature to hold all of your actionscript) and insert the following code:
instanceNameOfMovie_mc.addEventListener(MouseEvent.CLICK, nameOfFunction);
function nameOfFunction onClick(event:MouseEvent):void
{
trace(“You just made an event handler to handle mouse click events!”);
}
And you’re done! You’ve made a movieclip that acts like a button with event handlers!
Now, some of you may ask, “Why not just use a button?”. The reason, the gives you more flexibility, and this is your first step in learning how to control event handlers. There may be times when using a button may be more appropriate, but for now, this is the way to go.
You can see a list of what other “Events” can be paired with the “MouseEvent” listener here. Experiment!
3
Flash lesson 2: A Basic Understanding of Variables
A lot of you were looking at me with a weird face when I said that you were going to learn variables in Flash. So here’s a more indepth explanation.
A variable is a symbol, or container, for another set of data. For instance, we can say the variable “myName” = Ryan Paul Thompson.
Do you remember when we started doing math in school? Once we got to Algebra, we started using variables. We would get problems such as “1 + b = 3″, and then we would be tasked with figuring out what “b” truly was (2 in this case).
Now in Actionscript 3, creating variables is a little bit different from in actionscript 2. We used to be able to get away with simply typing myname = “Simon Belmont”;
Not anymore. In actionscript 3we are REQUIRED to use the var keyword first.
Translation: Use var to tell flash, HEY!, I’m creating a variable!
example: var myVariable;
this creates a variable named “myVariable”
Next to note, is that you also have to define what KIND of variable this is, what is it’s data type. You can define a data type as a String, is it going to be Number, a boolean, etc.,etc.
Translation: You have to tell Flash what kind of data, the variable is representin.
example: var myWord:String = “Words flash will then remember, in the EXACT same way that you type them”;
This creates a variable named “myWord”, and flash understands that “myWord” is a “String” with a value of “Words flash will then remember, in the EXACT same way that you type them”
example: var myNumericalValue:Number = 7;
This creates a variable named “myNumericalValue” that has a value of 7. Notice that 7 did NOT have quotation marks around it.
The second you put quotation marks around 7, flash understands it as a String, as a word, and can’t use it to count.
What good are variables? Let’s say you’re filling out an form…there is a variable that holds your email address, and pushes that data to a database so you’re client can receive that information. When you receive emails that say “Hello, Mike”, it’s pulling your information from a database full of variables. When you play Modern Warfare 2, and youg et a headshot, there are variables holding how many points that it was worth, and then adds your points up to level you up. The uses for variables are endless, and will become more apparent the farther along we go.
So that’s variables in a quick down and dirty nutshell.In the next lesson we’ll go over the trace command, and you can start putting those variables to use.
23
Actionscript Homework for Beginners #1
Ok kids gather round. This weeks flash/actionscript homework is a simple banner ad.
I want each of you to create a banner ad in flash for one of the following Television shows.
Arrested Development
Chapelle Show
WWE Raw
Oprah
Captain Planet
Here are the specs
300px height x 250px width
“Background” color MUST change from #FFFFFF to #333333 at some point in the movie.
Have at least one movieclip, where the insance name ends in “_mc”
Have one movieclip that is off the stage, that is placed on the stage by actionscript when the movie actually runs
At Least one object must be tweened. This does not have to be in terms of location (moving across the screen). You can tween alpha, brightness, tint, etc. (look at your properties panel after you create your movie clip and click it).
FPS must be 30
No more than 25 seconds.
File Size can NOT exceed 80k. (figure it out)
There can be pictures, or there can be words, all of that is up to you. This banner does NOT need a button, but if you feel up to the challenge, make a button that will send people to a site about the show you choose for brownie points.
And if you have any questions, drop them in the comments below, or email me.Good luck!






