Disney’s latest real-life tale of overcoming adversity is a slight but pleasant exercise in uplift that’s utterly familiar except for its African setting. One might describe Mira Nair’s “Queen of Katwe” as an Ugandan mash-up of “Akeelah and the Bee” and “Searching for Bobby Fischer”—a mixture that sounds stranger than it turns out to be.

Phioni Mutesi (Madina Nalwagna) is introduced as a nine-year old living with her family—led by her strong-willed widowed mother Harriet (Lupita Nyong’o)—in the dirt-poor shantytown of Katwe outside Kampala. Harriet exercises no-nonsense control over her and her two younger brothers, but Phioni’s older sister Night (Taryn “Kay” Kyaze) dolls herself up to attract the notice of a slick twenty-something motorcyclist (Maurice Kirya), with whom she soon goes off.

The circumstances of the family are hardly promising—they set up a stall at the outdoor market but make few sales and wind up begging merchants to give them food on credit and putting off their landlord’s demand for rent—but Phioni nonetheless shows an aptitude for chess at a local church-run community center. Robert Katende (David Oyelowo), the jobless engineer who’s added the game to the options available to the kids, notices her untaught skill at seeing many moves ahead, and encourages Harriet to support her daughter (and Phioni’s brother Brian, played by Martin Kabanz) as they continue practicing. Despite her initial misgivings that Phioni might begin to dream unrealistically (as Night had done) of possibilities beyond Katwe, Harriet watches her daughter’s ascent up the competitive ladder with growing pride.

Katende also manages to persuade the organizers of the country’s chess competitions that his crew, including Phioni, should be admitted to contests usually reserved for more privileged students at upscale schools. Naturally, her talent outshines her opponents, and she eventually not only wins a junior national championship but is invited to participate in international competitions, and though there are setbacks—not only in terms of her play, but because of family problems like an injury to Brian and the return of Night to the nest after a break-up—she eventually wins the title of Master, becoming a local celebrity in the process.

The goal of “Queen of Katwe” is clearly to inspire us with Phioni’s success, and it succeeds in some measure, thanks to Nalwanga’s sturdy performance. But it also works as a joint portrait of two strong, committed people who were instrumental in helping her. Nyong’o delivers an intense turn as Harriet, a woman utterly dedicated to keeping her children safe and well (a brief encounter with a shop owner played by Ntare Guma Mbaho Mwine, who offers her an alternative, is presented as evidence of that), while Oyelowo smoothly conveys the gentle, open disposition of a man whose own childhood deprivations lead him to go to extremes in aiding others in similar circumstances, despite the fact that he is also suffering from the effects of a system that has kept him from finding a job commensurate with his education. (The film also depicts the relationship between him and his wife in very sweet terms that indicate real sacrifice on her part.) The remainder of the cast provide fine support, even if some of them come across as a mite amateurish.

One of the film’s major selling-points is its ability to convey the colorful texture of the Ugandan locations. Director Nair and cinematographer Sean Bobbitt bring a genuine sense of place to the images—including those set at a competition in Russia—and Mobotaji Dawodu’s striking costumes make quite an impression. The overall production design (Stephanie Carroll), editing (Barry Alexander Brown) and music score (Alex Heffes) all maintain a smart professional standard.

Despite its virtues, however, the film ultimately comes across as overly formulaic but for its setting, a tale that might be more at home on the small screen. But it does conclude with an especially winning touch: during the final credits the actors are shown alongside the real people that they play in the film, and the juxtaposition is charming.