Hey, I’m working on a prop protection for my flood server. I tried to write a code, but it won’t work. There are no errors, just it doesn’t do what it’s intended to do. Here is the code.
function GM:Move(ply) if tr.Entity:IsValid() then if tr.Entity:GetNetworkedEntity("Owner") == ply || table.HasValue(tr.Entity:GetNetworkedEntity("Owner").Friends, string.Replace(ply:SteamID(),":","_")) then --Do nothing. else ply:SetVelocity(ply:GetForward() * 100 + Vector(0, 500, 500) end end end
Pretty much what I am trying to do is, if a player isn’t on someones prop protection to push the player off the prop. Is there something that I am missing? I appreciate any help that you give, just please give some useful information. THANK YOU!