Raccoons are very clever, and very persistent.
Yes, a .223 or a bit larger (personally, I'd use a .223 or a 357 magnum rifle - google marlin lever action, it's a very cool rifle, very accurate) will end the issue, for *that* raccoon.
Electric fence will solve all manner of problems, is cheaper, and you don't have to sit and wait for them to come to the hive. They came after the chickens, it's just a matter of time.
-T