Melody Thomas Scott Melody Thomas Scott

She just can't stay off the sauce. Daytime goddess Melody Thomas Scott, who plays recovering alcoholic Nikki Newman on CBS's The Young and the Restless, has booked a guest gig on CBS's The Crazy Ones as...a boozy librarian! The actress will share scenes with Robin Williams and Sarah Michelle Gellar in an episode scheduled to air mid-April.

"It came completely out of the blue," Thomas Scott tells TV Guide Magazine. "I was originally called in for another role on the show and was told by the producers that I was too young, which was fabulous! But they thought Robin and I would play off each other well, so they created a role for me in a different episode. It's a great character and not at all glamorous like Nikki. This poor girl is really trying to be sexy but she's just not cutting it — and she has no qualms about pulling out her flask during library hours."

Thomas Scott says the Crazy Ones team had watched her old episode of My Name is Earl and seemed inspired by it. "That was another role where I'm all drinky-drinky," she says with a laugh. "I guess it's never too late to be typecast!"

Working with Williams and Gellar was "wonderful and surreal and still hasn't sunk in yet," she says. "The whole thing has been crazy!" Thomas Scott has even more to celebrate this week: Thursday, Feb. 27 marks her 35th anniversary on Y&R

Subscribe to TV Guide Magazine now!