Prevent the crowbar from drawing when using c_crowbar

I’d like to make a SWEP that will let players pick up random bits of junk from the map and use that as their weapon. I intend to use a cut-down version of the SWEP Construction Kit. That part works, I’m drawing shovels, wrenches, etc, where the crowbar is.

The problem I’m having is that I can’t figure out how to make the crowbar disappear, either by making it transparent or shrinking it or what. I’ve found some other SWEPs that do this (zombie survival, for one), but I can’t for the life of me manage to untangle their code and figure out what they’re doing that I’m not.

What’s the minimum that needs to be done to achieve this?

Set the material to engine/occlusionproxy in PreDrawViewModel

That works great at making it disappear! However, for whatever reason all of my weapons are now invisible. They remain that way until I die and put the weapon back into my inventory. This seems very strange, as I put the SetMaterial in the SWEP:PreDrawViewModel hook, and not the gamemode one. Did I make a horrible mistake?

in PostDrawViewModel, set the vm’s material to “”

vm:SetMaterial("")

Thank you! Sorry you had to spoonfeed me there a bit. I was writing some godawful timer mess to set it back to that, but pointing out that hook really saved me some headache.