A man with a homemade shotgun was threatening and trying to rob passersby in the Guararí section of Heredia Tuesday.
When police arrived, the man tried to fire on the officers, but the weapon did not work. The device was a pipe installed with the grip of a pellet gun.
Police detained a suspect identified by the last names of Cortés Grajales.
When officers grabbed the weapon and tried to detain the man, they said he hit one officer in the face and tried to grab the sidearm of the second officer.
Homemade weapons are easy to construct, and low-budget crooks are likely to carry one. However, many of the weapons in use by criminals in Costa Rica are those that have been stolen from registered owners, such as security guards.