Shocking new details in the arrest of Cody Latimer ... cops say a witness claimed the NFL player threatened to "kill everybody" after a dispute over a poker game -- this according to court docs obtained by TMZ Sports.
Cops arrived at a Douglas County, CO residence around midnight Friday, the docs show, after they received a call about possible shots fired.
Once they showed up ... officers say in the docs they interviewed Latimer's friend, Roderick English, who explained to them the Washington Redskins receiver snapped after an argument over a card game.
Cops say English told them he was playing host to a poker night at his place with his GF, Latimer and a few other buddies ... when Latimer got into a dispute with another person.
English claims he broke up the altercation and booted everybody out ... but told cops Cody showed up a half-hour later, pissed off.
Cops say English told them Latimer pulled out a firearm and said he had saved two rounds of ammunition for English and his GF. Cops also say English told them Latimer threatened to "kill everybody."
English told officers Latimer calmed down ... said he wouldn't kill anyone and "removing the magazine and clearing the chamber" of his gun.
But, according to the docs, Latimer grew angry again ... and that's when English says Latimer fired two shots near him.
Cops say English told them he then wrestled with Latimer ... but claims the 27-year-old hit him on the head with the gun, causing a contusion and a cut on his head.
Ultimately, the altercation was broken up ... and officers arrested Cody, booking him on several felony charges, including assault and illegal discharge of a firearm.
For his part, Cody's attorney said in a statement to ESPN's Adam Schefter regarding the incident, "There’s an entire back story to this situation that constitutes one of the most highly provocative situations you can imagine. Please withhold judgment until all the facts of what took place that night are known."
Latimer, who was a second-round pick of the Denver Broncos in 2014, has a court hearing set for Monday in the case.