This is an archived article and the information in the article may be outdated. Please look at the time stamp on the story to see when it was last updated.

NEW YORK (PIX11) — NYPD detectives found a loaded, AR-15 assault rifle under the mattress of alleged cop killer Lashawn McNeil, officials said Monday.

The discovery was made Saturday after detectives secured a search warrant for the Harlem apartment where McNeil had been staying with his mother and brother on West 135th Street. The NYPD tweeted a photo of the assault weapon late Monday afternoon.

McNeil, a 47-year-old ex-con, was accused of ambushing the two officers when they went to speak to him in a back bedroom inside the apartment. Officials said McNeil died Monday of injuries sustained during the shootout.

NYPD Chief of Detectives James Essig said McNeil used a Glock 45 to shoot the young officers, Jason Rivera, who was a 22-year-old rookie, and Wilbert Mora, a 27-year-old officer on the job four years.

Both officers were shot in the head. Rivera was pronounced dead shortly after the shooting. Mora suffered a significant brain injury and he was transferred Sunday evening to NYU Langone Medical Center.