In Rosedale last July, Zachary Buza shot at officers during a three-hour police standoff.
Over a dozen state troopers and sheriff's deputies filled the Parke County courtroom Friday morning for the sentencing hearing.
The judge said he found inconsistencies between Buza's testimony and what he said during the investigation.
Buza faced 74 years on all counts, but got a 40-year sentence, with 6 years suspended and some credit for time served.
In court, Buza said he's planning to appeal his conviction.