BOISE - A 24-year-old Boise man on Tuesday admitted to buying beer for two teens before one of them died in a crash last May.

The Ada County Sheriff's Office said Cole J. Dyer pleaded guilty to a misdemeanor count of dispensing alcohol to a minor in connection to the crash that killed 17-year-old Clayton Tully early in the morning on May 29.

Tully had graduated from Meridian High School the day before.

Tully and other youths had gathered in the desert south of Kuna for a graduation party. At some point, Tully and two other boys decided to go for a drive.

Tully was behind the wheel when his pickup overturned going around a corner on a dirt road east of Swan Falls Dam. He and a 15-year-old passenger were flung from the vehicle as it rolled.

Deputies found the crash site a short time later and called for the air ambulance.

Tully died of at the scene. The 15-year-old boy was seriously injured and was airlifted to a local hospital. A 16-year-old passenger suffered only minor injuries, and was able to call 911.

RELATED: Sheriff: Boise man bought beer for teens hours before boy died in drunk-driving crash

According to the Ada County Coroner's Office, Tully's blood-alcohol content measured at .275, more than triple Idaho's legal limit for an adult of .08.

Investigators spoke with the teens at the party and learned they had already been drinking when some of the youths left to get more alcohol. That's when Dyer bought beer for the teens, just hours before the deadly crash, investigators say.

Deputies arrested Dyer in November as part of the investigation into the crash. He is scheduled for a sentencing hearing on April 27.

The crime of dispensing alcohol to a minor is punishable by up to a year in jail and up to a $1,000 fine.