But before I explain what it is, lets answer what you’re wondering. Why should I care.
If actionscript helps pay your bills its safe to assume that while there’s a rewarding aspect and beats ditch digging, there are necessary evils which serve no purpose other than preventing you from getting in more quality xbox time. If you’re like me, you dream of repetitive stress injury related tasks being wrapped up in a single class or method. More importantly, you want to know that the wrapper is clean, tight and leak free, or to put it another way, as good or better than what you would have written. In short, you should care because the example below took about 45 lines of code including declarations and typical syntax.
Now it’s tempting to describe the HYPE actionscript framework as a tool belt but that just conjures up images of a refrigerator repair man crack and all or a carpenter feverishly pounding nail after nail in some modern depiction of Dante’s Inferno. No man, this is Batman’s fricken utility belt! We’re talking batarangs and grappling hooks, not table saws and power drills. This is dispatching foes in style without breaking a sweat, not sheet-rocking the basement!
I would get into the inspirations and origins but I think the authors are already doing a great job of that on the projects home page, http://hype.joshuadavis.com and in their videos at http://www.vimeo.com/channels/hype. Instead I’ll play the slap-chop shamwow guy (sans battery charges and death threats) and tell you what ya get.
Looking at the HYPE actionscript framework demos you might think that the required use is to combine some of the HYPE classes to create some cool patterns or generative motion graphics. You’d be half right. The key is that each core module does something powerful, quickly. The samples merely highlight that fact by demonstrating that when used together, its harmonious.
ObjectPools & ObjectSets
Likely you’ve run into the situation in object oriented actionscript where you have many instances of the same class or subclass that require iterative treatment and populating arrays and dictionaries just sap the energy you’d like to put into the logic you want to apply to each instance. HYPE provides an ObjectPool class which manages ObjectSets and together provide a “just add water” approach to dealing with large numbers of objects in a way that’s actually fun. The boolean operations of ObjectSets alone are worth the price of admission. ObjectPools are like gumball machines in that they allow you to check objects in or out of a container without having to deal with internal details such as checking to see if any are available. “THWACK!”
Rhythms, Triggers, and Behaviors
A rhythm quite simply calls a function repeatedly at a frequency set by you using one of a few predefined types of time. And it does this without AS3′s much maligned event system. Depending on your needs, calls can be made upon entering frames, exiting frames or intervals. The cool part is being able to set a frequency so as to run a callback method every 5th frame. Not everything needs to be updated at every single opportunity. Like a rest in music, rock is what you don’t do. Such is the rhythm module.
Triggers are similar to rhythms, only they are conditional. They fire when a condition is met. You might say they are like events, but you’d be wrong. They don’t get broadcast, get added to listener lists, propagate or spend memory. Like a laser guided flame-throwing sentry, they just fire.
Behaviors also take from the rhythm mindset in that they do something frequently but are autonomous in that they strive to be in a certain condition without just snapping to it. Following in a mouse cursors footsteps is different from just reading its x and y values. “POW!”
Sound, Bitmaps and Layouts
The features I’ve already described should be enough to get anyone’s creative juices headed down a path that no doubt will pass through performance town. HYPE will be there to greet you.
Learning how to animate with actionscript code and the desire to sync it to sound are about two seconds apart. AS3′s sound classes allow for powerful use of what’s coming out of your speakers but doing so can be enough work to defeat any desire to do so. HYPE pinpoints Flash actionscript’s most common use scenarios and brings it right to your table piping hot. Its like this thing we used to call customer service. No Flash mp3 player should ever be without an equalizer again.
When Flash grew up from a mere vector animator it got all raster on us. Ironically an inverse of what used to redraw faster, bitmaps have become a go to format for refreshing the screen faster. The HYPE actionscript framework Canvas module allows you to skip adding a ton of children to the stage while praying for smooth playback and instead will paint the resulting composition to a single bitmap on the stage. And it makes doing so ridiculously easy. As a bonus a whole world of filters and additive painting opens up.
All this asset management is awesome and should arranging them on screen be any less fun? HYPE’s Layout module does things out of the box you might have argued against even being possible! Laying out objects in a grid had never been easier but act now and you even get the ability to place objects within the confines of other objects! Now that’s cool.
HYPE is not just a tool set belt, its a mindset. It represents years of Mr. Joshua Davis’s successes and failures using computers as an art tool and is the result of Mr. Branden Hall’s resilience to extract every ounce of power from the Flash player. It’s worth trying out one or two of the modules because almost infectiously, HYPE will start to be the core of how you use Flash actionscript creatively.
Wow I made it all the way through that without saying “Believe the HYPE.” … wait. Crap.