What made this episode, entitled Awakening, so incredible is that Joss Whedon gives us an ending to all of the show's current issues tied up in a nice little bow, and then dismantles it all, and with just a single line, leaves the whole thing in a painful, ugly mess. The plots had all been resolved with a disappointingly fairy-tale ending, and I can't believe I didn't expect that Whedon would pull something along the lines of the "it was all a dream" ending, except far more spectacular.
The "big bad" at this point is the Beast, a being far more powerful than vampires, sons of vampires, and physicists, so Angel and his gang are unequipped to stop him from ending the world. The Beast begins his apocalypse by covering the sun in LA so that vampires and demons that can only come out at night can have the city as their playground at all hours. Cordelia has a vision that tells them that Angel was once involved with the Beast, possibly made a deal with him, and is able to be controlled by the Beast without remembering any of it - including their first meeting. The key to unlocking this mystery is to extract Angel's soul, because the meeting occurred with his former soulless vampire self. That's why Wesley finds a shaman to take Angel's soul and let them talk to the most cunning and ruthless vampire in recent history - Angelus.
However, as they prepare to have Angelus as a house guest, welding a 10 x 12 steel enforced cage to the basement walls, the shaman appears to reveal himself to be working for the Beast by trying to kill Angel. This leads to a succession of events that are incredibly fortunate for Angel. They get a new lead from the shaman, meaning they don't have to extract Angel's soul and bring back the homiopathic killer that could harm his friends, and find out that there is a magical sword conveniently located in LA that can destroy the Beast.
On the mission to retrieve the sword, all of Angel's dreams come true and the show's issues are resolved. After saving Cordelia from danger, she confesses that she loves him and apologizes for refusing to be with him after she saw images of his dark past. He has a standoff with his son Connor, who thinks everything that is cruel in his life is Angel's fault, but when it comes down to fighting the Beast, and Angel is about to be beaten, Connor jumps in, saves his father, and apologizes for being so angsty and whiney. Even Wesley says he is sorry, something he never does in reality. Essentially, Angel has had the best day of his life and he gets to end it in Cordelia's arms. But if you've followed me this far, it's because you know the show and you know that for Angel, perfect, pure happiness means the loss of his soul.
I would like to take a sec and reiterate this crucial Whedon premise. This is potentially the best use of the vampire legend I have ever seen, and just further solidifies the crappiness of Stephenie Meyer, as I said here and here. Angel is not Edward. He isn't some "good" vampire, a vegitatarian who just thinks killing humans is wrong. That goes against the whole point of the vampire legend, that it would be possible to lose everything that makes one who they are and, being a soulless bloodsucker, make them want to bleed dry everyone they ever cared about. Now that's dark and interesting. Edward being different from all the other soulless bloodsuckers for no other reason than morality is just lame.
So anyways, Angelus is cursed with a soul to make him suffer the pain and heartache of all of the things he has done, and he has done some dark things. In just a few hundred years he's killed hundreds of people, and he's such a sadistic lunatic that he finds ways even to stab in the heart the people that he doesn't have a chance to kill. For example, instead of killing Holt's daughter and drinking all of her blood, he turns her into a vamp so that her father has to kill her himself. Angelus makes Drusilla completely insane by chasing her across the continent, killing everyone she comes into contact with, and by the time he makes her a vampire she's lost it.
That said, the ending to this episode is far more weighty than the cliched "it was all a dream" scheme. Angel experiences a moment of true happiness, signifying to his gypsy persecutors that their punishment is not harsh enough, and he loses his soul, becoming Angelus again. But that's not all, folks. As it turns out, the entire perfect experience Angel has had - uncovering the sun, killing the Beast, bonding with his son, and copulating with Cordelia - has been a vision given him by the Shaman that induces the spell - the extraction of Angel's soul. When the Shaman says "the vision becomes reality", we understand that none of that happened, it was all just a hallucination, and part of the spell to rid Angel of his soul. His world is still in pieces, and his friends still need to use Angelus to find out how to stop the end of the world. As usual.
ADDITION: I just remembered another key moment of Angel's "perfect day" hallucination, showing how Whedon pretended to tie up all the loose ends. At one point when he and his son Connor are fighting the Beast, and the Beast continues to address Angel as Angelus, Connor looks up and corrects him, saying, "His name is Angel". Of course that would be the Angel's dream of his son finally coming to accept that he is a different man from the monster Angelus. Such a well done episode.