Kicking off with a full-scale alien attack on Earth, the science-fiction boy’s adventure “Ender’s Game” throws everything in the whiz-bang arsenal at us. There’s a satellite martial academy where child warriors train in free-floating combat. There are battles between interstellar fleets that litter the screen with more space shrapnel than a dozen “Gravity”s. In the end we even get to see an entire planet disintegrate.

And yet all the spectacle never works up your emotions. Many sci-fi fans swear by the greatness of Orson Scott Card’s 1985 bestseller, but this film adaptation, aspiring to high seriousness, is merely glum. The film plays like a dark, solemn junior-high version of “Starship Troopers,” and it leaves you bored senseless.

The film is set 50 years after a catastrophic battle with an insectoid alien race put Earth on permanent (and totalitarian-tinged) military alert. Asa Butterfield (“Hugo”) plays gangly, soft-featured Ender, a star student in the military school that prepares kids to lead a counterattack against the ant-like Formics. His older siblings didn’t qualify for the prestigious program. Sis (Abagail Breslin) was too empathetic, and brother (Jimmy Jax Pinchak) had an overdeveloped killer instinct. In Ender, the mix is just right. He’s sensitive enough to understand the enemy, and ruthless enough to use that intuition to defeat them. Plus, he’s a whiz at computer combat games.

J.K. Rowling’s Harry Potter series was published years after Card’s “Ender” but it came to the screen first, with many similar scenes and parallel situations. There’s a sense of déjà vu as we’re marched through the off-Earth boarding school where the students divide into rival squadrons and compete in Quidditch-like flying shootouts. They play so many rounds of float-and-zap that the first hour of the film feels like a laser tag documentary.

The futuristic visual cues lifted from “Avatar,” “Independence Day” and “Star Wars” are too numerous to mention. There’s even Harrison Ford doing his gruff thing as the battle school’s growly headmaster. Where those earlier films sizzled with invention, and gloried in the old tropes they borrowed, “Ender’s Game” drowns in its somber undercurrents. The hazing Ender endures has a sour, cruel edge, and his aggressively violent retaliation is off-putting. The story eventually arrives at an antibullying moral, but it takes a harsh path to get there. As Ender himself puts it before his change of heart: “Follow the rules, you lose. Choose violence, you win.”

When Ben Kingsley appears, with Darth Maul/Maori face tattoos and a zany New Zealand accent, he gives the film a sudden lift. Playing the fighter pilot who defeated the first wave of alien invaders, he brings a spot of high style to the movie, his voice commandingly intense.

But this new mentor arrives too late to save the film’s flagging momentum. The film’s other true acting sparkplug is Moises Arias as a rival youth commander determined to make Ender’s life hell. Strutting like a power-mad Junior ROTC officer, he gooses every scene he appears in, and there are too few before he’s abruptly written out. Writer/director Gavin Hood (“X-Men Origins: Wolverine”) doesn’t condescend to the material in this young-adult space melodrama but he never gets a dramatic grip on it, either.