The most evocative shot in James Gunn's largely enjoyable space opera Guardians of the Galaxy comes relatively early in the proceedings.

Peter Quill, who would rather you call him Star-Lord, has settled down on an uninhabited planet to rob it of a mysterious artifact. He's an Earthling by birth, so, like many of us, he comes complete with a constant stream of pop music coursing through headphones, serving as a soundtrack, and as he makes his way toward the artifact, Redbone's "Come and Get Your Love" pumps through the speakers.

Gunn pulls back into an extreme long shot, isolating Peter at the bottom of the shot, emphasizing the alien landscape surrounding him as he dances to the tune. The title of the film fills every space on the screen above where he spins and twists, oblivious to the destiny the words above him spell out. It's Gunn's vision for these Marvel Comics characters in a nutshell: the most seemingly insignificant of beings, turned into the largest of heroes.

It's a mission statement the film only fitfully lives up to. There are moments when this is one of the best movies Marvel has ever come up with, where the momentum of the film gathers everybody up and rolls heedlessly downhill. There are also moments when it succumbs to a kind of stentorian boredom that seems jackhammered in by committee.

Guardians is wildly inventive in one scene, and frustratingly typical in the next. It's the kind of movie that will pause for a beautiful, tiny, human moment between two characters (even if they're a raccoon and a walking tree), then follow that up with a scene where somebody just point-blank tells someone else their back-story and motivation, simply because that's what the plot requires of them at that moment.

It's mildly impressive Gunn and co-screenwriter Nicole Perlman keep the film on course as long as they do. Virtually everything necessary to the plot is conveyed in the film's first 10 minutes, with Peter's back-story on Earth getting filled in via a handful of scenes and moments of emotional resonance, before the film cuts to his adventures as an adult in the farthest reaches of space. Yes, the artifact he's pursuing is of the utmost importance. And yes, he'll be joined by a ragtag band of would-be heroes as they attempt to figure out what to do with it. You've seen these beats before, but Gunn and Perlman have a real comfort with both the trappings of the story and with finding ways to subvert it.

A crew of space weirdoes

Guardians is always at its best when it focuses on Peter and the space weirdoes who become his crew. The great, sardonic Chris Pratt, best known for playing Andy on TV's Parks & Recreation, essays Peter here, and he turns in a performance that's something like what might happen if Han Solo became a character in Knocked Up or another Judd Apatow movie. Pratt nails every laugh line he's given, and he makes one of the most convincing cases for rakish movie stardom in quite a while. Guardians will send his career into the stratosphere, and he deserves it.

He's joined by four others, thrown together by circumstance when they all end up in the same prison early in the film. Our second lead here is Gamora, a green-skinned alien woman raised by supervillain Thanos and played by Zoe Saldana. Gamora's acutely aware of the evil she's been party to and hopes to rectify it, and Saldana, no stranger to films like this, thanks to Avatar and the Star Trek franchise, gives her a moral weight that helps keep the movie from floating into the ether. Saldana and Pratt have real chemistry, and there are moments between the two of them that threaten to burble over into actual romance, which has rarely been a threat in previous Marvel movies not starring Robert Downey, Jr., and Gwyneth Paltrow.

Also joining Peter and Gamora on their adventure are Rocket Raccoon and Groot, voiced by Bradley Cooper and Vin Diesel, respectively. Cooper occasionally pushes Rocket's antisocial behavior too far, but he settles in nicely as the film goes on, while Diesel reminds viewers of how good he was in Iron Giant with only a few spare words. The walking tree Groot, who by and large only says "I am Groot," is another wonderful creation, and Diesel gives that three word phrase a variety of textures and meanings.

The final member of the crew is Drax, an alien played by Dave Bautista. The character seems a typical heavy for a while, but Bautista ends up offering nearly as many laughs as Pratt, as he leans into Drax's inability to understand anything but the most literal meaning of what's said.

In the scenes where he gets to bounce these personalities off of each other, Gunn has great fun with everything from the dialogue he and Perlman have handed to the actors to the filmmaking. In particular, the staccato editing of these sequences gives the whole film a nervy, edgy feeling that keeps the audience nicely off-balance. Guardians takes a while to assemble its team and gets everything going, but once it heads into its third act and becomes the caper film it's been threatening to become all along, it builds up a head of steam that is awfully hard to resist.

Boring bad guys

Or it would be, rather, if Gunn weren't forced to fit the film into the larger Marvel franchise framework. The fact that the Marvel movies all occupy the same universe has had huge implications for the film industry as a whole, and when this is done well, it's thrilling to watch pieces snap into place across multiple films. But it's not done particularly well in Guardians, where Gunn and the film's interest wanders every time they have to turn their attention to the story's villains, the evil Ronan (Lee Pace), who is evil for reasons that are mostly glossed over, and Nebula (Karen Gillan), who is Gamora's sister.

The scenes checking in on the evil plot are mostly a snooze, largely consisting of exposition and attempts to work bits and pieces of the larger Marvel mythology into the proceedings. Gunn even seems to film these sequences like those bland BBC historical dramas from the ‘70s and ‘80s, while Pace, Gillan, and others stand around and declaim things in stentorian tones. The sense of fun that follows through everything with the Guardians is gone, and even the editing slows down, as if not sure how to handle this much infodumping. The film tries throwing actors at the problem — Glenn Close! John C. Reilly! Peter Serafinowicz! — but they, too, are gobbled whole by its blandness.

Worse, this means that the stuff with the Guardians can only have the approximation of emotional resonance. The characters remind each other a lot of their own separate pains, and the script is careful to give Peter an object into which he can pour his sadness and longing. But the characters' emotional arcs by and large exist on a path that runs parallel to the main action.

At its heart, Guardians wants to be about the assembly of a makeshift family after one's biological family is gone, but because it doesn't have the time to make these moments stick, it settles for blatantly telling us this is what it's doing and confusing that for emotional depth. Similarly, the story development settles for being a collection of pieces awkwardly wedged together, instead of anything like a coherent plot.

That may sound too harsh for a movie that is, ultimately, a lot of fun, but there's a much better version of Guardians so close to the version we actually have that it becomes frustrating to notice it peeking through every so often. In some ways, it's heartening that Guardians plays around with what we expect a Marvel movie to be by now. It's shot through with genuine wit and occasionally earned pathos, and it's pitched much more as a ragtag heist film than anything else.

Except when it's not. Ultimately, the underlying structure here is the underlying structure Marvel always uses, and though the tone may be different, the film is playing the same tune the studio always does. Guardians succeeds when it proves the Marvel formula is malleable; it fails when it discovers that formula is not yet malleable enough.