[ pattern_13 ]
 
contact: jlacoutu@gmail.com
Some of the menu generatrion I've done with Ming is interesting...
The base code for each of these menus is the text_generator

capoeirabrasilboston.com

When I began working on capoeirabrasilboston.com, there was already a design in place. This image on the left is the original menu as created by the original designer. He used a gif approach, where each link (events, classes, etc..) is created individually in photoshop.

So everytime the owner of the site wanted to add a new link, I had to create a new image for the menu. This was difficult, having never met the original designer on top of having no knowledge of the fonts used. I decided there had to be an easier way.



The idea was to create some type of animated menu while sticking with the original design. I figured out the basic idea - a script that could take in a couple of arrays (one for the english word, one for the portuguese word, and one for the link), and generate some textfields that would do something nice on rolloever. This is the base - loop over each string and add an onenterframe action to it:

$onenterframeActions .= "
//check for a hit on your hitArea
if(box".$string.".hitTest(_xmouse, _ymouse)){
//do something cool
}
else {
//undo the cool thing
}";

The menu on the left flips the english and portuguese words by altering the _y and scale values of each string.
The menu on the right uses the random number generator to scale and rotate the text.

This was a cool little side project that demonstrates the power and dynamics that ming gives to the developer.