I would agree that the fencing is much better investment and should be the first task/option.
Having said that and ignoring the legal issues (there are some) I must say that I use paintball guns and airsoft guns against the persistent predators. Those are the predators that sit about ten yards...