Two teenagers held up a Stranraer grocery store to get money for video games and jewellery, a court has heard.
The two teenager admitted holding up the Stranraer store
The robbers, aged 13 and 14, walked into the shop on 4 January with their faces masked, pointed an air pistol at an assistant and demanded money.
The pair, who cannot be named for legal reasons, admitted assaulting the shop worker, threatening her with violence and stealing money and cigarettes.
Sentence was deferred to 11 July when the defence mitigation will be heard.
The offences were committed at Leafield Stores in the town's Woodland Road.
Glasgow High Court heard that shop assistant Emma McKeown, 27, had at first refused to hand over cash believing it was a joke.
The 14-year-old then moved closer to her and pulled a lever at the side of the gun which made a clicking sound.
On hearing this, Ms McKeown feared for her safety and handed over a quantity of money and cigarettes.
After the two accused left the shop she dialled 999.
"The 14-year-old boy cycled from his home to his friend's home," said Alastair Carmichael, prosecuting.
"With him he had the gun, a mask and a bag.
"He said he wanted to rob a shop and his 13-year-old friend agreed to join him after making a mask out of an old pair of trousers.
"The 13-year-old believed the gun was real."
The court heard that after the raid a number of witnesses saw the boys running away with their faces masked.
Police searched their homes after receiving a tip-off.
In the 14-year-old's home they found cigarettes, money, a balaclava and jewellery bought with the proceeds.
In the 13-year-old boy's home police found cigarettes.
The court was told that in total £174.30 in cash was recovered along with computer games and jewellery which had been bought with some of the proceeds.
Judge Lord Hodge told the pair: "You must be aware how bad and anti-social what you did was."
He deferred sentence on both until 11 July at the High Court in Edinburgh for background reports.