Articles Tagged "ActionScript"

Random Candy Colors

If you saw my recent “Candy Cosmos” post, you may have noticed that the randomly generated colors tend to be rather “vibrant”.

rainbbowgradient.jpg

Pure red, green, blue, cyan, magenta and yellow colors appear frequently, while pure black and white colors occur occasionally, and colors near 50% gray tend to be the least common. The bright candy colors are a side effect caused by
Read More

Hexadecimal Color Fading

A while ago, I wrote a Color Fading tutorial for ActionScript.org which provided nearly all the functions you’d ever want for fading colors. Did you notice that I said “nearly”? Well, today I’ve added yet another weapon to my color-fading code arsenal called “fadeHex”. The name probably won’t put fear in the hearts of fellow code warriors but it’s a powerful tool none the less. In essence, it lets you specify two colors, then creates a color gradient from the first color to the second and lets you choose a color at any point on that gradient.
Read More

Flash ActionScript Date Suffix Code

I’ve become fairly familiar with the Flash Date object and thought I’d share some handy code showing how to append the proper suffix to a date or any other number. In case you don’t know what I’m talking about, a “number suffix” or “ordinal indicator” is the string of letters that follows a number to help make it more human readable. For example the number suffix “nd” makes “May 2nd, 2007″ a little easier to read than “May 2, 2007″.

Here’s the code I wrote to handle all my numeric and date suffix needs:
Read More

Something About Sluggy

A long long time ago on a Flash forum far far away… I was trying to grasp the full implications of the “text editor thingy” inside Flash. Supposedly, you could type magic words into it and Flash would obey your every command. Finally! My computer would do my bidding rather than it forcing me to press CTRL ALT DEL and string consecutive expletives together in new and exciting ways.
Read More

© Sean O'Shell 2007-2012