A man caught with a baseball bat hidden up his sleeve was fined £400.
Thirty-two-year-old Colin Brown, of Lanton Place, admitted having an offensive weapon in Rosevale Street.
Police saw him walking in the community close there with an object hidden up his sleeve.
He told the officers that “he and another had gone to sort out a problem”, explained procurator fiscal Morag McLintock.
“I was trying to give it back to the guy who owned it,” added Brown.
Solicitor Rory Bannerman, defending, said his client – who admitted a £20-a-day cannabis problem – was “spending too much money on cannabis, which is underpinning his health problems”.
“A financial penalty would restrict his ability to buy cannabis,” he added.
Sheriff Donald Corke warned Brown: “This is the sort of thing for which you could easily be sent to prison.
“Given your difficulties, I am not going to go down that road, but you are spending too much money on cannabis.
“If you can spend that much buying cannabis, you can easily afford a fine,” he concluded.