Where to put GM code

I need to have props nocollided while being physgunned to prevent propsurf

Someone linked me to:

http://wiki.garrysmod.com/page/GM/PhysgunPickup and http://wiki.garrysmod.com/page/GM/ShouldCollide

But where do I put the code at?

Bump. Please help.

They’re hooks. Normally if you’re not making a gamemode then they would be used with a hook.Add(). If you’re looking at something that makes prop no-collided when they’re physgunned, you’d have to be careful so that people don’t freeze props into other players.

By the way, PhysgunPickup is a serverside hook, and ShouldCollide is a Shared hook, meaning it’s on both the client and server.

garrysmod/addons/lua/autorun/file.lua would create a shared file and inside you’d add a function to the event using hook.Add()

Wrong section, post @ http://facepunch.com/forums/65