I was recently introduced to CASA Lib by my friend and fellow Flash developer, Scottae, and I have to say I’m quite amazed. This extensive library is jam-packed full of things that I’ll be using over and over to make my life a lot easier. It’s stuff like this that you’d think would be native to Flash anyway, but isn’t. In my years programming games, I’ve started to move towards coding like this anyway, but the guys who developed this library do it FAR more efficiently and elegantly than I ever would have. Go ahead and dig into the source code – it’s all there and it’s beautifully executed. The documentation is thorough and detailed as well. The only complaint I have is that I wish there were even more concrete examples buried in the documentation (like Adobe’s documentation). Here’s a few of the features I am particularly fond of:
- Any object that can dispatch events can now be created extending RemovableEventDispatcher which tracks all those pesky event listeners automatically and gives you easy, convenient methods for cleaning them up in one line
- The commonly used display objects are recreated (CasaSprite, CasaMovieclip, etc) with a destroy() method, giving you a neat and tidy way of doing everything to make them immediately available for garbage collection
- An inactivity monitor to easily integrate code that needs to run when the user sits there idle (perfect for games)
- A class that can register for and respond to key combinations being pressed at the same time or in a specific order (again, perfect for games)
- A plethora of new utilities that address situations where we have all said at one point “man, I wish there were something built in to Flash that can [insert common process here]” – too many to list here
I’ve only been through about half of the classes so far, so I’m sure there are a ton of other really nifty things that I haven’t even discovered yet. Mega kudos to Aaron Clinger and Mike Creighton for spearheading and managing this library. I can’t say enough good things about it! This has been a godsend for my game programming and I’m looking forward to incorporating these new classes into my projects.
OFFICIAL SITE: http://casalib.org/
Enjoy!
- George