The indie film “The Inevitable Defeat of Mister & Pete” tells a story of bad luck transformed because its stubborn, proud heroes refuse to surrender.

The film’s creators have taken that moral to heart.

“Mister & Pete” debuted to acclaim at the Sundance Film festival in January but hasn’t attained the theatrical success that many anticipated. Undeterred, the film’s screenwriter, Michael Starrbury of Brooklyn Park, took the plunge, personally guaranteeing the distributor “at least two sellouts” if it would book the film near his home.

Now “Mister & Pete” is opening Friday for a two-week run at the AMC Southdale 16. And Starrbury is “calling everybody I know” to attend. It’s a do-it-yourself stunt that his movie’s underdog duo would cheer.

Starrbury is well known in local film circles. A three-time winner of the IFP/McKnight Artist Fellowships for Screenwriters, he sold a TV series pilot to Comedy Central in 2011 and his script “Watch Roger Do His Thing” made the influential Black List of Hollywood’s best unproduced screenplays.

In the movie industry he’s valued for his knack with writing action comedies, but “Mister & Pete” was something out of the ordinary. It’s a picaresque yarn about two stray children growing up too fast over a tough summer in a Brooklyn housing project.

The script’s gritty atmosphere and ultimately optimistic message attracted an impressive roster of talent. In front of the lens there’s Jennifer Hudson, Jordin Sparks, Anthony Mackie and Jeffrey Wright; behind there’s pop star Alicia Keys as composer and executive producer, and George Tillman Jr. (“Faster”) as director. Tillman fell in love with Starr­bury’s script in 2009 and spent three years pulling together the $3 million project.

Hudson leaves behind the show business glamour of “Dreamgirls” to play a drug-addicted single mother whose 13-year-old son, Mister (Skylan Brooks), is struggling to raise himself. When she is forced into rehab, he finds himself reluctantly saddled with Pete (Ethan Dizon), a younger boy with an air of angelic innocence. Fending for themselves, they evade the city’s child protection services, pulling together to confront their difficult circumstances.

Shari Frilot, senior programmer for the Sundance Film Festival, called Brooks’ cheeky debut as Mister “a stunning breakout performance.” Critics agreed, giving the film a glowing 89 percent positive score on the film-review website Rotten Tomatoes. The New York Times called the film’s emotional appeal “naked and unembarrassed” and its young stars “irresistibly charming.”

Still, the film struggled on its release earlier this month. Lionsgate opened it in just 147 theaters nationwide, failing to get a booking in Minnesota before Starrburry intervened.

“There was no money to promote the film,” Starrbury said, so cast and crew boosted the film on social media. “Audiences have responded to our film,” he said, recalling e-mails, letters and post-screening encounters with viewers who were moved to tears.

“I got a note from a girl who said she was debating whether or not to become a teacher. She saw the movie and decided to become a teacher. It does not get better than that,” he said. “We just need to let them know that it’s available.” Starr­bury recalled a Tweet from a screening that said, “I’m the only person in this theater. Why is that?”

“That stings,” he said.

On Friday, Starrbury will be present to introduce and discuss his film at the Southdale multiplex. “I enjoy talking about the film, the socioeconomic themes in the movie” as well as the inevitable questions about whether the experiences onscreen are autiobiographical. (They aren’t.)

“It’s frustrating, and I don’t want it to seem like this is all about money. I don’t need to do ‘Gravity’ numbers,” he said with a laugh. Still, it might be nice to help the investors get their money back. So far, “Mister & Pete” has earned about $500,000.

Starrbury said that barring “some kind of a miracle,” the film will soon go out of theaters into DVD and video-on-demand release. “That would actually be pretty cool,” Starr­bury said. “People will be able to find it that way. They’re at home and it’s easy to go to iTunes and find this new release. ‘I’ve heard about this. I didn’t know where I could go to find it, but now it’s right in front of me.’ Netflix could tell them, “If you liked ‘Pursuit of Happyness’ or found ‘The Blind Side’ interesting, you would like ‘Mister & Pete.’ That could be great for getting people to see the film, so I’m looking forward to it.”

After a season of theatrical struggle, home video may provide “Mister & Pete” its hard-won happy ending.