Hipmunk for the iPhone - here's how we built it
blog.hipmunk.com
blog.hipmunk.com
Kudos on a sweet app! I'm looking forward to seeing what you guys build next!
Oh, and thanks for sharing! If everyone was more open about the tools they use, I think apps would be a lot better in general.
Kudos to Steve and Adam on hiring Danilo.
From a UX perspective, I’m really pleased with how
the pinchable, stretchable, draggable time bars came
out in the application. They feel really good to use.
But from a development perspective, this is some of
the stupidest, craziest code I’ve ever written in my
life. Don’t ask me how I did it because it did it
entirely the wrong way. Maybe I'll share once I figure
out the non-stupid approach.
But this is perhaps the most interesting part of the app that you should talk about. I'm okay with seeing the stupid implementation :)Hard to be that guy.
Maybe. Or maybe someone would point out that you took a wrong path, you'd be embarrassed for a few minutes and learn the better design pattern way faster.
I say this, but it's not something I do. I'm working on it though.
The awesome:
- Fucking persistent corner rounding for rectangles. So you can adjust the size without screwing up your round rects' corners. WTF, Photoshop? How hard is this to do?
- edit: ALSO, easy Retina display support. No thought required
- Factories, as described in my post
- Badass pen tool for bezier shapes. Anchor points snap to guides in a very intuitive way, as do those fiddly little handles for curvy anchor points. It's much easier to create an arbitrary shape in Opacity than it is in PS or Illustrator.
- Much more flexible layer layer styling than Photoshop. Want two strokes on that vector? Fuck yeah, there you go.
- Variables. No shit. So, say you want the same button in five different colors. Set up a color variable, tie it to the button's fill property, then set up five factories with different color variables. Change the button's appearance, then the factory will dump out five brand new versions identical to your new changes
- Code generation: So maybe you suck at Quartz or want to use a GUI to create a starting point. Build your image in Opacity, then use the "Source Code" factory type. It'll spit out native drawing code using the drawing library of your choosing (Cocoa, Quartz, Core Animation). Variables work with this, too.
What needs improvement:
- Drawing performance is spotty, especially when dealing with bezier vectors. I see more pinwheels than I'm used to in Opacity, and that's on a late 2010 machine. This has been improving – I sent a sample file to the dev and he made some optimizations that helped a lot. Still, needs more work here.
- If you've built your existing UI assets in Photoshop, there's no easy way to get them into Opacity. You're probably going to end up recreating them, but since Opacity's tools are for the most part much better, this isn't terrible. Gives you a chance to spruce things up.
I had way more than $90 worth of headaches on my last iOS project keeping UI assets straight. I had no automated workflow; it was "do this in Photoshop then change the color manually for each one and then probably forget once or twice to export the correct resolution and tear my hair out wondering why it looks like crap."
I absolutely hated making minor iterations to the design, because I'd have to waste half an hour changing everything for a few pixels difference.
Thanks for the recommendation on this!
Integrate it with Xcode and treat your vector artwork as source -- when you build the project it will spit out all the little PNG files you need at all the different sizes. Your artists just tweak the opacity files, and when you build the PNGs get made. So awesome. We had to buy an extra copy for the CI server, but it was worth it to never again need to sit around and export png files.
Plus, if you need to draw something with Quartz, you can mock it up first in Opacity, and then have it generate the source code for your drawing, which you then integrate into your class. We quickly made classes that implement dynamically blurred drop shadows, customized numeric "badges" of any size, shape and color, and so on, just by drawing the effect we wanted, generating the source code, and combining the drawing code into a custom class. So awesome. Feels like cheating. (You have to work around Quartz's lack of Unicode support, but still.)
Whoa, really? Badass. How do you set this up? Have a link?
"Opacity includes opacityutil, a command line utility that can convert images between the formats supported by Opacity. You can use this functionality in Xcode to create a Build Rule that will dynamically convert .opacity images in your project to TIFF files (or any other supported format) at compile time."
Wow, that's worth the price of admission alone. Writing drawing code by hand takes forever and is the worst kind of time sink: the almost-but-not-quite mindless kind.
Danilo: How did you pitch them? Or did they pitch you?
You have mad design skills (Opacity does rock) for a coder. Dangerous!
Short version: I wrote a post about Hipmunk that got Adam's attention, then didn't leave him alone until he gave me the gig. Here's the longer story, if you're curious:
https://developer.apple.com/videos/wwdc/2010/
.
Edit: removed wrong link
http://www.codinghorror.com/blog/2006/11/the-project-postmor...
We collect the following data points via a single third party tool, namely Flurry. There aren't any others, aside from the obvious booking partners who book your flight at the end of the process.
- How long is the import process
- What tasks throw exceptions or otherwise crash the application
- Which cities are most chosen
- How far into the future do users most often search
- Do people bother with flights displayed lower on the screen
- Do people bother with the alternate booking mechanisms we made
This is useful to both confirm initial hunches on how the app's UX should work and helps direct modifications and enhancements in future versions. Flurry collects UDIDs for a promotional program they do for app discovery but Hipmunk doesn't participate in that.
Actually if I am not mistaken, it is against the app store TOS to submit a UDID to a third party without the user's consent. Apps that use Flurry's agent in particular took heat from Apple for this. This is basically spyware.
http://www.tuaw.com/2010/06/02/flurry-agrees-to-stop-device-... http://forums.spybot.info/showthread.php?t=57992
Really, there is no reason to track activity by UDID for booking a flight.
I am not trying to troll here - I actually love your website. But I really hate spyware!
For your other uses, most reputable apps ask the user if they would like to participate in a customer feedback program, and inform them what will be collected, and allow them to opt out.
Deleted comment
(just launched on Tuesday)