• OnPhysgunFreeze Hook Help/ents.FindInSphere Help
    3 replies, posted
Solved
Posting the same thread twice isn't going to work; you aren't giving full code.
[QUOTE=code_gs;50563057]Posting the same thread twice isn't going to work; you aren't giving full code.[/QUOTE] That is the full code what more do you want?
Sorry, I thought the bottom was an addition to your top portion of code. [code]if SERVER then util.AddNetworkString( "PlayerTrap" ) hook.Add("OnPhysgunFreeze", "CheckForPlayersInProp2", function(Weapon, Phys, Ent, ply) for k,v in ipairs(ents.FindInSphere(Ent:GetPos(),400)) do if v:IsPlayer() then Ent:SetCollisionGroup(COLLISION_GROUP_WORLD) net.Start( "PlayerTrap" ) net.Send(ply) break end end end) end if CLIENT then net.Receive( "PlayerTrap", function() notification.AddLegacy( "You can not freeze a prop with a player inside it!", 1, 4) end ) end[/code]
Sorry, you need to Log In to post a reply to this thread.