If it isn’t quite “Rocky Balboa plays baseball,” the recently released film “Bottom of the 9th,” starring real life couple Joe Manganiello and Sofia Vergara, carries more than a bit of that underdog vibe. It’s a fun, understated movie about a gruff New Yorker, a star baseball prospect broken bad, who receives a second chance after getting released from prison. And it also knows its baseball, as it features some fun nuances about the game itself.

As it turns out, the tale behind the making of this motion picture is even more of a triumph of the little guy than its fictional counterpart. Best of all, this backstory features people involved in the actual “Rocky” series.

Screenwriter Robert Bruzio, a Bronx native, was working at his family’s construction company as well as delivering auto parts on the weekend to make ends meet as he tried to grow his small production company. He first conceived the idea for this movie all the way back in 2003, after he spent time with a close relative who had been behind bars. Bruzio’s first big break arrived when he met…Paulie?

“When I had my production company, I befriended Burt Young,” Bruzio said in a telephone interview, referring of course to the beloved actor who plays Rocky’s brother-in-law. “We had to put him in. He had a restaurant in The Bronx, and I did a couple of commercials for his restaurant. He took a real liking to me. I started helping him with a film project. We did a short film together. He invited me to the set of ‘Rocky Balboa,’” the sixth movie in the saga.

On that set, Bruzio met producer William Chartoff (whose father Robert produced all six “Rocky” films plus the first “Creed”) and showed him his script. Chartoff liked it enough to become an advocate and eventually a “Bottom of the 9th” producer.

Through his newfound “Rocky” connections, Bruzio delivered his script to John G. Avildsen, the director of the original Sylvester Stallone classic as well as “Rocky V” and “The Karate Kid.”

“Within two days, John Avildsen calls me back and says, ‘I love it. I want to do it,’” Bruzio said.

Alas, Avildsen got sick and died in 2017. Raymond De Felitta came onto direct it instead, and with the support of an enthusiastic Manganiello, the film survived many scares and production delays to come to life. It filmed in 2017, with many scenes shot at Richmond County Bank Ballpark at St. George, the Class A Staten Island Yankees’ home. That occurred thanks to the help of producers Robert Molloy, one of George Steinbrenner’s grandsons, and Ray Negron, a longtime Yankees adviser who has a small role in the film. There are additional Yankees touches like cameos of a famous retired legend as well as a front-office executive who isn’t particularly popular at the moment (OK, it’s Brian Cashman).

And, best of all for “Rocky” lovers, the 79-year-old Young has a small role as a coach. “We had to put him in,” Bruzio said. How else to authenticate this underdog story?

“Bottom of the 9th” is available on demand as well as in select theaters.

This week’s Pop Quiz question came from Tyler Kepner of Wilton, Conn.: In a 2002 episode of “The Sopranos,” Paulie watches a Yankees game on TV. What Yankee of that era can be seen hitting a home run?

The New York State Hall of Fame’s inductees for this year include the late Thurman Munson and Bobby Murcer, beloved New York pitching Rons Darling and Guidry and Negron. The event will take place on Sunday, November 3 at the Hilton Hotel in Troy. Those interested can call 518-877-5170 for more information.

Your Pop Quiz answer is Jason Giambi.

If you have a tidbit that connects baseball with popular culture, please send it to me at kdavidoff@nypost.com.