Warning: This review contains spoilers for The Mandalorian season 3 episode 7.

Any Mandalorian fans who were complaining that season 3 seemed directionless should be appeased by the penultimate episode, “Chapter 23: The Spies.” This episode pays off all the season’s ongoing storylines as Mando, Bo-Katan, and their blended family of Mandalorians return to their homeworld to reclaim it, only to find that someone else has already claimed it. There’s a handful of thrilling action set-pieces, a great new development for Grogu’s character, and a heartbreaking final scene that will stick with audiences for a while.

Moff Gideon is back with a vengeance. The Mandalorian’s big bad is reintroduced on a conference call with all the other Imperial Remnants leaders, collectively known as the Shadow Council, all working under Grand Admiral Thrawn. Gideon questions Thrawn’s leadership and suggests dethroning him, setting up an intriguing storyline, either for The Mandalorian’s future, Ahsoka, or the recently announced New Republic v. Imperial Remnants movie to be directed by Dave Filoni. It might have seemed like a cop-out to reverse Gideon’s defeat from the end of season 2, but Giancarlo Esposito’s unparalleled on-screen presence is an instant reminder of why Gideon is such a great villain and what makes him so crucial to the series.

RELATED: Star Wars: What Ahsoka Can Learn From The Mandalorian And Book Of Boba Fett

With steam rising from sewer grates and ominous droids lurking in back alleys, the episode’s neon-lit opening scenes on Coruscant offer a glimpse at the Blade Runner-esque sci-fi noir fans were robbed of when Rangers of the New Republic was canceled. From then on, this episode is a treat for the eyes. Unlike most Volume-based cinematography, this episode deftly conveys the scale of the criminal underworld of Coruscant, the stolen Imperial fleet flying overhead, and the desolate post-apocalyptic wastelands that remain of a bombed-out Mandalore.

Moff_Gideon_in_a_hallway_in_The_Mandalorian

Rick Famuyiwa gets back in the director’s chair after helming some of The Mandalorian’s best episodes. Famuyiwa brings “The Spies” to life with impeccable direction. The episode crams in all the story threads from the entire season to pave the way for next week’s finale, but it never feels rushed; Famuyiwa gives every scene the room it needs to breathe. Most Mandalorian episodes will have one or two great set-pieces, but this episode is full of them. From the Mythosaur attack to the combat ritual to the final battle between the Mandalorians and the Imperial Remnants, Famuyiwa nails every action sequence.

The introduction of IG-12 is a great payoff to the seemingly inconsequential subplot from the season 3 premiere in which Mando tried to resurrect IG-11 and ended up turning him into a top-half Terminator. The little droid engineers that viewers met back then have been working on him ever since and have managed to recreate IG-11 as a sort of vehicle for Grogu. Much to Mando’s chagrin, this cybernetic suit gives Grogu more freedom for mischief.

Famuyiwa was the director who established Mando and Grogu’s dynamic in his first Mandalorian episode, “Chapter 2: The Child,” so he was the perfect choice of filmmaker to introduce a whole new dynamic between the characters in “The Spies.” With Grogu piloting the exoskeleton of an IG droid, not only can he speak to his father figure for the first time (albeit only using the words “yes” and “no”); he’s now the taller of the two. This makes it difficult for Mando to parent him. If Mando tries to confiscate something, Grogu can just lift it out of his reach. This is a hilarious new development for the character – Grogu’s immature behavior and Mando’s frustration with it get a big laugh every time.

Grogu_pilots_IG-12_in_The_Mandalorian

Grogu’s new robotic body isn’t just used for humor; it exemplifies other aspects of his character. Giving him more power shows his capacity for mercy. He uses his IG body to break up a fight between Mandalorians from competing factions. Grogu stands between the two fighters and hits the “no” button repeatedly until they back down. Bo-Katan tells Mando that he’s taught his apprentice well, but Mando tells her Grogu didn’t learn that compassion from him. Perhaps the kid learned it from Luke Skywalker or one of his previous Jedi masters, or it’s simply a sign of Grogu’s innate goodness.

In the episode’s captivating final scene, Paz Vizsla goes out like a hero. Vizsla wasn’t a particularly likable character prior to season 3 – he was always the guy who gave Mando a hard time – but he’s gone through a redemption arc of sorts throughout season 3. He’s been shown to be a loving, protective father, and he’s warmed up to Mando. He galvanized his fellow Mandalorians to help Mando when he needed it. This week, he ended up nobly sacrificing himself to buy the others enough time to escape. Vizsla went down swinging: he managed to fight off the entire Stormtrooper squad before being outmatched by Gideon’s Praetorian Guards. This ending gives Vizsla a heartbreaking death scene, but it also establishes the stakes ahead of next week’s climactic battle.

Season 3 has been a little uneven up to this point, but “The Spies” is the best episode of the season so far. It sets the stage for an action-packed finale: Mando has been captured, Bo-Katan’s leadership has been challenged, and the Mandalorians’ quest to retake Mandalore has been scuppered by a similar plan already underway by the Imperial Remnants. “The Spies” provides all the pew-pew action Star Wars fans could hope for – and plenty of laughs, particularly involving Grogu’s new cybernetic exoskeleton – but the episode also delivers a couple of emotional gut-punches.

MORE: Skeleton Crew Might Be The Most Visually Distinctive Star Wars Show