A lorry driver has been jailed for six years after an incident in which he was shot by Staffordshire Police officers.
David Shepherd, 40, of Burnthill Lane, Rugeley, was hit in the arm and hand as he pointed a ball bearing gun at officers near a school.
Stafford Crown Court heard that he had just split up from his girlfriend and had been drinking heavily.
Armed police had been called after Shepherd's former partner received threatening texts.
The court was told that Shepherd, who was separated from his wife, had sent the messages in the early hours of Friday 18 August, which included an image of him posing with the imitation pistol.
That afternoon she called police, who arrived in Burnthill Lane to find Shepard waiting in a car, brandishing the weapon.
He was told several times to lower his weapon during the incident, in which baton rounds were fired followed by four shots, two of which hit him.
Shepherd was later charged with assault, two counts of threatening to kill, affray and possession of an imitation firearm.
The judge described it as a "dramatic and frightening incident".