Cop killed in alleged gunfight with colleagues