SAN FRANCISCO (Reuters) - A man who took a video of himself surrounded by flames that erupted into one of the worst California wildfires of 2014 was fined $60 million and sentenced to 20 years in prison after pleading guilty to arson on Friday, officials said.

Wayne Allen Huntsman, who initially pleaded not guilty to setting the nearly month-long King Fire, changed his plea and admitted to three counts of arson to forest land with enhancements for causing injury to firefighters and destruction of property.

“I plead guilty because I did it,” Huntsman told the court on Friday, according to assistant district attorney Dave Stevenson.

The fire blackened nearly 100,000 acres, destroyed at least a dozen homes and displaced thousands of Northern California residents southwest of the Lake Tahoe resort area.

Huntsman was sentenced to prison and ordered to pay $60 million in restitution to the victims, the El Dorado County District Attorney said in a statement.

The fast-moving conflagration was sparked on Sept. 13 and spread through the Eldorado National Forest in the central Sierra Nevada mountain range over the 27 days it took to control the blaze.

A handful of the thousands of firefighters who responded suffered nonlife-threatening injuries. At least 12 homes and around 100 other structures were destroyed by the flames.

Prosecutors said Huntsman fled the scene of the fire and encountered a Good Samaritan who offered to give him a ride out of the area.

Huntsman showed the driver a selfie-style video he took of himself standing between two of the fire’s points of origin.

“Listen, I got fire all around me,” Huntsman says in the video, which was provided by the prosecutor’s office. “I’m stuck in the middle, babe.”

The driver made a recording of the video and turned it over to investigators, prosecutors said. Huntsman was arrested within days of the fire’s start.

(In April 8 story, corrects headline to read “gets” instead of “get”)

(Reporting by Curtis Skinner in San Francisco; Editing by Sara Catania and Matthew Lewis)