Jayme Deerwester

USA TODAY

Rainn Wilson, whose best-known character, Dwight Schute, fell for dozens of pranks on The Office, will be the one doing the fooling in CBS All Access' upcoming Star Trek: Discovery.

On Friday, CBS announced that the 51-year-old Wilson has signed up to play Harry Mudd, a "charismatic conman and intergalactic criminal" in the latest Star Trek TV project, expected in late summer of fall.

Wilson is a three-time Emmy nominee for his work as the Office's irascible, beet-farming, wannabe autocrat.

Look for Mudd, who sounds a bit like The Next Generation's Q (John de Lancie), to tangle with the Discovery's Captain Lorca, who will be played by Harry Potter alumnus Jason Isaacs and his second-in-command, Lt. Cmdr Rainsford (Sonequa Martin-Green, The Walking Dead).

CBS had intended to use the space drama to launch All Access' original programming slate, but delays led the network to move up The Good Fight to February and postpone Discovery's rollout until late summer or early fall.