Warning: SPOILERS for DC's Legends of Tomorrow Season 5, Episode 13 - "The One Where We're Trapped On TV"

Here is every TV and movie reference in zombie apocalypse - and Sara Lance (Caity Lotz) did perish at the hands of the zombies - were magically transported into various TV shows by Charlie AKA Clotho (Maisie Richardson-Sellers), in order to protect them from her sisters, Atropos (Joanna Vanderham) and Lachesis (Sara Strange) AKA the Fates.

At the conclusion of last week's Legends of Tomorrow episode, "I Am Legends", Clotho was forced to reunite with her sisters and use the Loom of Fate to bring order to the world. This resulted in reality being changed into a bleak, brutal and fascist world ruled by the Fates reminiscent of George Orwell's 1984. (Director Marc Guggenheim also visually homaged Terry Gilliam's Brazil). Mona Wu (Ramona Young) and Gary Green (Adam Tsekhman) toil in this bleak reality, where their only recreation is to watch TV. Later, Mona and Gary discovered Clotho's algorithms for trapping the Legends on TV in her headquarters, Clotho Productions. When the Legends became fully aware of their predicament, they broke free of the Loom of Fate's control and chose to fight the Fates.

Related: Legends of Tomorrow Season 5 Visits Dick Grayson's College (Does He Exist?)

Legends of Tomorrow season 5, episode 13 is one of the most hilariously bizarre hours the Arrowverse's weirdest series has ever produced. But beyond the spot-on recreations of three of TV's most popular shows, the episode also resurrected Behrad Tarazi (Shayan Sobhian) and magically brought back the original incarnation of Zari Tomaz (Tala Ashe), who was reunited with her love Nate Heywood (Nick Zano). Clotho also brought Sara back from the dead and reunited Astra Logue (Olivia Swann) with her late mother Natalie (Alice Hunter), resolving John Constantine's (Matt Ryan) promise to Astra. All of this happened while the Legends hopped through the following TV realities.

Ultimate Buds (Friends)

Legends of Tomorrow Friends Ultimate Buds

Ultimate Buds perfectly homages Arrow." Nate and Zari also have a Ross and Rachel-like sexual tension. Nate also said, "Could I BE more of a kiss-misser?" just like Chandler would. Later, Mona and Gary wear white Ultimate Buds T-shirts with logos identical to the Friends logo.

Highcastle Abbey (Downton Abbey)

Legends Of Tomorrow Downton Abbey

Highcastle Abbey is a brilliant parody of John Constantine ran with. Constantine's house in Northumberland County, UK is transformed into Highcastle Abbey with Mr. Constantine serving as its butler, although Highcastle Abbey is in Yorkshire, where Downton Abbey was set. The Logues, Lady Astra and her mother Lady Natalie, are the upper-class family who lives in Highcastle Abbey.

Behrad is transformed into Lord Behrad Tarazi, who is supposed to marry Astra just like Lady Mary Crawley's hand was sought by numerous suitors in Downton Abbey. Lady Astra also yearns to go to London, which the Crawleys visited many times. Like Downton, there's the regal upstairs where the Logues reside and a downstairs area where the servants work, designed to look similar to the downstairs section of Downton Abbey. Nate and Behrad also joke about "what happened to the first footman", a nod to how Downton lost footmen as the series progressed.

Related: Legends of Tomorrow: Every Historical Villain In Season 5, Episode 10

Star Trip (Star Trek)

Legends of Tomorrow Star Trek

Star Trip lovingly recreates original Starship Enterprise.

Nate, Zari, Constantine, Astra, and Behrad appear as Gromulans, a mock-up of the Romulans, and Constantine offers Sara and Ava "rare Gromulan tea", a nod to Romulan ale. Mick Rory (Dominic Purcell) is transformed into Khan (Ricardo Montalban) from Star Trek II: The Wrath of Khan, complete with his wild, white hair and bare chest. The Faterider's crew turn out to be androids like Commander Data on Star Trek: Picard. Ava also deduces that the Groumlans are from an alternate timeline, something the crew of the Faterider "deals with all the time", just like the various Star Trek shows have. A giant hand also pulls the Gromulan ship into Mr. Parker's Cul-De-Sac just like the giant green hand of Apollo once captured Kirk's Enterprise.

Mr. Parker's Cul-De-Sac (Mr. Rogers' Neighborhood)

Mr Parker Cul de sac

Mr. Parker's Cul-De-Sac is a cable access show and parody of Mr. Roger's Neighborhood. This is its second appearance in Legends of Tomorrow after Arrow).

Next: Why Legends of Tomorrow Keeps Recruiting Its Villains To The Team

DC's Legends of Tomorrow airs Tuesdays @ 9pm on The CW