| Subcribe via RSS

Cool stuff from 360|Flex

May 21st, 2009 | 1 Comment | Posted in 360|Flex, Development, Flex

There were a lot of great sessions at 360|Flex this year. As usual, the tech sessions were very well presented and informative, but I found the new business track and the design centric sessions particularly helpful. It was great to gain some insight into how companies like Universal Mind and Phenomblue manage projects, their creative processes and just get a general glimpse into their inner workings.

I learned a lot and had a ton of great conversations with my fellow Flex coders, but there was also quite a bit of new stuff that was either announced at 360|Flex or came across my radar for the first time that I thought I’d list the ones that interested me the most. So, without further delay here is my list, in no particular order.

Axiis (http://www.axiis.org)

Axiis is an open source project for creating data visualizations. It’s built on top of Degrafa and is meant to make building simple charts extremely easy while providing tools to facilitate the creation of much more complex interactive visualizations. If you’re doing anything in the data visualization space, or currently using the Flex Charting stuff, then this is what you should be looking at. Check out the examples (http://www.axiis.org/examples.html) and don’t forget to right click and view the source.

FlexUnit 4 (http://opensource.adobe.com/wiki/display/flexunit/FlexUnit)

FlexUnit is the pinnacle of unit testing for Flex. It’s been updated to include all of the functionality of its JUnit counterpart, but rather than a direct port it was built specifically with Flex in mind. I attended a session on this and a few things really struck me. First off, it’s very easy to implement, using metadata tags. It now handles asynchronous calls very easily, which has been kind of difficult in Flex unit testing in the past. They also added a lot of extra features, like Hamcrest support for asserts, which means you have asserts like “closeTo” where you can check if a value is within a certain variance. Another great addition is Theories and DataPoints, which allow you to run the same test with a series of different inputs.

Basically, if you were putting off trying unit testing or have tried and found that the tools were too immature in Flex then it’s time to give it another shot. FlexUnit 4 is mature and seems to have been really well thought out.

Check out the slides from Jeff Tapper’s presentation which goes over some of the new features: (http://blogs.digitalprimates.net/jefftapper/index.cfm/2009/5/20/FlexUnit-4-feature-overview)

Bifff (http://bifff.seanhess.net)

I think this was the most exciting new thing I discovered at 360|Flex this year.

Bifff, or Behavior Injection Framework For Flex, is completely, incredibly, awesome. It’s JQuery for Flex. If you’ve ever used JQuery’s selectors then you’ll immediately understand the power that this library brings to Flex. You can very easily apply modifications to visual classes in your app by finding them by id, style name, class type or class ancestors like interfaces or base classes. Want to make all Canvases with a stylename of “draggable” draggable? Just add a few lines of code and it’s done. The other great thing that Bifff adds is the ability to assign mutiple style names to an object. Fex can’t do this natively, but Biff will combine them so you can have something like <mx:button id=”mybutton” stylename=”mybuttonstyle largefont redtext”/> where the mybuttonstyle might be a basic style for all buttons, largefont is a style that sets the font size to 16 and redtext makes the text red. Additionally, you can then reference any one of those styles to inject additional bahavior into the button.

If my description doesn’t really make sense then just go to the GitHub site and look at the examples (http://wiki.github.com/seanhess/bifff). I think the power will become apparent after you view the source there and get a feel for what Bifff can do.

Glue (glue.seanhess.net)

Glue is a framework similar to Mate that was built by Sean Hess using Bifff. Because its built on Bifff the data injection that is core to Mate is taken to a new level and at the same time simplified. It makes for a simple to use, unobtrusive, and very lightweight framework.

StandingWave (http://code.google.com/p/standingwave/)

StandingWave is a sound sampling library for Flash and Flex. The demo presented in the closing keynote was pretty impressive. The library allows you to take wav and mp3 samples and algorithmic sound generators and sequence them across time hierarchically. It also allows you to apply effects like echo and fade. It was built for use in the Noteflight application (which is incredible in its own right) and looks to be incredibly useful to anyone looking to generate sound or sequence music in Flex.

I know there were more, but these are what came to mind first. Of everything I saw I have to say that Bifff was the most useful for the type of work I do, and also the most unexpected. The session on it was a write-in at the last minute and if Sean Hess hadn’t been given a few minutes in the closing keynote to explain what Bifff was I don’t think I would have attended his session and discovered this amazing tool.

Some other quick observations from sessions I attended and conversations with others in the Flex community..

  • Cairngorm and PureMVC are out, Mate is in.
  • FDT is an incredible editor for Actionscript and now Flex as well. I mean, really productive x10 incredible.
  • Flex 4 is going to be awesome. Spark is a game changer in terms of component creation and skinning.
  • Flex 4 will use Degrafa style code, but the flex compiler will convert it into actual flash player shapes during compilation, making for much improved performance.
  • The Flex community is incredibly open and friendly. Everyone wanted to talk about the work they do, problems they face and where they felt they were and weren’t overcoming them.
  • Tom and John put on a great conference!

That’s all I’ve got for now. I’ll post individually about the projects I listed here as I get to know them better, and will be looking forward to next year’s 360|Flex.

So it begins.. [Ninja vs Robots]

May 5th, 2009 | 1 Comment | Posted in Development, Ninja vs Robots, iPhone

I’ve been messing around in xcode lately playing with some iPhone development, getting myself comfortable with the editor, objective-c and the Cocos2d library in preparation for some serious game development. After a few weeks of kicking the tires I think I’m comfortable enough to start working on a real game, so tonight I sat down to go over the ideas I’ve been kicking around to pick one.

Picking one idea out of the five or so in my head, knowing what a huge commitment it is to finish a game, is a bit daunting. After much back and forth, pros and cons, I decided to just sit down with flash and start sketching some things out. Almost immediately this little guy popped out: (go ahead and hit the play button to see some crazy ninja action)

So, Ninja vs Robots (tentative title) it is. As of right now the basic plan consists of a side-scrolling free-roaming platformer (Metroid style) with some story to it and hopefully some fast-paced and interesting game play. This is going to be slow going, I’ve got a lot of other stuff on my plate and this’ll be a background thing, but expect to see something, oh I don’t know, sometime in 2011? Well, hopefully sooner than that, but you know how it is. It’s ambitious - I thought about doing a more casual game at first - but I know the types of games I want more of on my iPhone and this is it, so I’m going to skip the casual game phase and jump right into what gets me all happy.

I’ll post little updates here as I flesh out the concept more and start putting some gameplay together on the iPhone itself.

Why I still like books.

October 6th, 2008 | 1 Comment | Posted in Development

I could be completely off base on this, as I have done zero research to support my hypothesis, but I sometimes feel like I am one of maybe four developers who are fairly advanced in their careers and still turn to physically printed paper books when getting serious about learning a new language or concept.

Reading about complex material on the internet, for me, is akin to sitting in a classroom where you’re attempting to learn while trying not to stare at the liberal arts hottie with the cool tattoos and piercings, ignoring several juicy conversations going on around you, keeping yourself from opening letters that the mailman is inexplicably delivering straight to your desk every two minutes, with a guy walking into the room every few seconds yelling “Hey! Anyone interested in the new Fallout 3 game? Follow me!”

This takes serious amounts of discipline and patience, a certain level of which I shall never achieve. Granted, this can also lead to some very interesting tangents that are often fruitful as well, but if I need to really immerse myself in a subject there is still no substitute for the isolating nature of a physical book and a quiet reading area.

I acknowledge that in this incredibly fast-paced field most books are usually outdated before they even hit the shelves, but I’d point out that one of my favorite books that I reference from time to time is a data structures textbook published in 1994. All of the code examples are in C and assembly, and yet I’ve used the concepts in every language I’ve encountered - from perl and coldfusion to pre-actionscript flash and AS3/Flex. A solid developer deals in algorithms and concepts and therefore a decent book (or any resource for that matter) can be invaluable if you can abstract the really important stuff from the syntax. But that’s a huge topic for another post.

Setting the default size of a Flex Skin

September 8th, 2008 | 1 Comment | Posted in Development, Flex

The web serves as my long term memory these days, so when I can’t find something fast enough via google, I need to post it here.

Here’s a quick post to remind myself in the future that the measure() function resides in UIComponent. Since ProgrammaticSkin extends FlexSprite and doesn’t have a measure function to override, you have to override get measuredWidth() and get measuredHeight() in order to define the a default size of a skin.

Archive Utility Annoyance

June 8th, 2008 | 3 Comments | Posted in Development

Yesterday I encountered a situation that I suppose most people wouldn’t have even realized happened, but for me turned out to be a case of my computer trying to be a little too helpful. It all started when I was attempting to decompress an archive containing a .swc file - basically a zip file that flex can use as a code library - but instead of the .swc, I got folder containing its contents. It took me a minute to realize what I was looking at, but when I did I thought to myself “well, that’s annoying.” It turns out the default behavior for the archive utility is to decompress the archive and if the only file in it is another archive it keeps going. It assumes that’s what you’d want, which I guess for most people it is.

The inconvenience this caused me was only mildly annoying, but what really got me was when I realized there was seemingly no way to change that behavior. I could forgive this if it was just a feature built into the Finder app, but I noticed that for the split second while my file was being expanded that the Archive Utility app was displayed in the tool bar, meaning that it is an actual application.

After looking in all of the usual places applications are stored on a mac I finally found it, thanks to WikiPedia, at /System/Library/CoreServices/Archive Utility.app

Ahh, System/Library/CoreServices, I wonder why I didn’t I just look there in the first place?
Archive Utility property panel
It seems trivial, but really, why build a full application with toolbars, additional features, and a properties panel, and then not give the user an obvious way of getting to any of it? I can picture the conversation now..

“The archive utility will go in CoreServices.”
“But sir, we put all of the other utility applications in Applications/Utilities, don’t you think that will confuse the users?”
“Nobody should ever actually have to run it. When a user clicks on an archive it’ll open up, unarchive the files, and then disappear before the user even knows what hit them, that’s what we call a seamless user experience, Johnson!”
“Sounds more like a ‘wham bam thank you mam’ experience.. Why did you make me spend all that time on the interface and program in all of those preferences if nobody will ever get to see or use it?”
“Don’t you have some TPS reports to fill out or something?”

Oh well, at least I was able to get to my .swc.

  • Who am I, you ask?

    Matt Guest is a RIA developer, enthusiastic coder, independent game developer wannabe, sometimes artist, amateur home brewer and a pretty decent dad and husband to boot.



    email: matt@mattguest.com
    twitter:mguest
    wave:mattguest@googlewave.com

    Subscribe to the feed.

    Interested in iPhone development? Check out my site dedicated to iPhone game development at brokenPlatypus.com