Katy Perry may have been the guest-star attraction on this week’s How I Met Your Mother, but this nicely intricate episode shifted the focus away from her to focus on Jennifer Morrison’s recurring Zoey.

Indeed, Perry was used as bait for both viewers and the show’s characters. Playing Zooey’s “hot cousin” known only to us as “Honey” (because her ditzy gullibility inspired Marshall to say, repeatedly, “Oh, honey!”), Perry wiggled and batted her eyes and played a very funny scene with Neil Patrick Harris’ Barney, totally buying into the romantic con-man’s claims that, among other things, he has four Nobel Prizes.

But the half hour was really about Ted’s crush on Zoey, and how being in love with a married woman affected all of the show’s characters. One of the consistent charms of How I Met Your Mother is that, while the show talks a nice game of naughtiness (Barney, of Ted, re Honey: “He fell on his sword so she could fall on mine”), the series has a moral center about the notions of friendship, commitment, and loyalty.

HIMYM continues to make the aftermath of the death of Marshall’s father believable rather than just a plot point to flee from for the safety of comedy. In fact, the episode hinged upon the idea that we heard about the Ted/Zoey dilemma via phone calls to Marshall, who’s still with his remaining family in Minnesota. (Jason Segel plays the scenes with his mother and brother with lovely exasperation.) In a cross between Rashomon and the kids’ game Telephone, we heard and saw a series of misunderstandings between the pining Ted and the married Zoey.

Jennifer Morrison also gave a wonderful performance this night. Every time I see her now, I think that she was suppressing comic-romantic talent behind the grim mask of Cameron on House. It was fun to see her and Perry work their charms on the HIMYM cast, and to see the cast respond with typically adroit skill.

What did you think of this week’s How I Met Your Mother?

Twitter: @kentucker