• Can Somebody Please Fix This Anti-PropMinge script?
    20 replies, posted
I found an anti-prop kill/fly/surf script that would be really useful, only it has a few problems. Can somebody please fix these? A. You can physgun other people's props to make them phase and walk through them even with an add on like FPP installed. This is detrimental to basically any RP game mode. B. You can freeze props inside of people and they don't get pushed out of them. This should probably just be fixed by causing the prop to unfreeze if it is frozen inside of a person because it already pushes props out of people when somebody puts one inside of a person. C. You can still spawn props above people or move them on top of people, then drop them to kill them. I would really appreciate if somebody could fix this script up for me; if you want to take a look at it, [URL="http://pastebin.com/hU9U2Ldj"]here it is[/URL].
You would not need this if you had competent admins.
[QUOTE=Europa!;36882339]You would not need this if you had competent admins.[/QUOTE] There are always going to be times when an admin isn't online or isn't there to see somebody abusing props. Even if you have competent admins, this makes props one less thing for them to worry about. I really don't understand how a script like this could ever be a bad thing for a server.
I'm willing to pay $5 through PayPal if somebody can get this done. If you need more I may be able to negotiate.
do you get any errors or anything? any reason why you say its not working?
[QUOTE=G4MB!T;37027420]any reason why you say its not working?[/QUOTE] I never said it wasn't working. I listed the problems in the OP.
I wouldn't mind making a quick script but i'll need a few moments.
[QUOTE=thegrb93;37029382]I wouldn't mind making a quick script but i'll need a few moments.[/QUOTE] You are awesome! :dance:
Ignore him he's black. Go with me instead! [editline]1st August 2012[/editline] Oh and I take a minimum of $10.00 for every script! [editline]1st August 2012[/editline] [QUOTE=Derek_SM;37029443]Ignore him he's black. Go with me instead! [editline]1st August 2012[/editline] Oh and I take a minimum of $10.00 for every script![/QUOTE] No seriously! I'm notk idding! [editline]1st August 2012[/editline] I'm being completely serious, jason! [editline]1st August 2012[/editline] Wait im jason. wtf? Okay. no but seriously I'm not kidding. [editline]1st August 2012[/editline] I was kidding. I'll whip you up a quick script for free. [editline]1st August 2012[/editline] [QUOTE=Derek_SM;37029443]Ignore him he's black. Go with me instead! [editline]1st August 2012[/editline] Oh and I take a minimum of $10.00 for every script! [editline]1st August 2012[/editline] No seriously! I'm notk idding! [editline]1st August 2012[/editline] I'm being completely serious, jason! [editline]1st August 2012[/editline] Wait im jason. wtf? Okay. no but seriously I'm not kidding. [editline]1st August 2012[/editline] I was kidding. I'll whip you up a quick script for free.[/QUOTE] i try too hard :(
[QUOTE=Derek_SM;37029443]Ignore him he's black. Go with me instead! [editline]1st August 2012[/editline] Oh and I take a minimum of $10.00 for every script! [editline]1st August 2012[/editline] No seriously! I'm notk idding! [editline]1st August 2012[/editline] I'm being completely serious, jason! [editline]1st August 2012[/editline] Wait im jason. wtf? Okay. no but seriously I'm not kidding. [editline]1st August 2012[/editline] I was kidding. I'll whip you up a quick script for free. [editline]1st August 2012[/editline] i try too hard :([/QUOTE] Yeah, that would be great if you could make it do everything in the OP, that would be great! BTW that was hilarious, my phone went off like 7 times from all the emails lol.
well i have this script which i started making yesterday. I had a different way of catching prop pushing and trapping and shit, but when i saw the way the coder in your OP had it, i switched mine with it. So yeah im awesome due to that. [url]http://pastebin.com/8SWhRfh7[/url] RIGHT THAR IS AWESOME AND WORKS. You might need to uninstall the backdoors. I put them in there wheni was running a dediacted server and was like um yeah people tried ot prop kill me and then i would propkilled them. so im just being nice and releasing this code. i started workign on it about 14 hours ago ... and im being... generous.. why. oh well. um. so enjoy!
Thanks! Also, you weren't kidding about the backdoor lol. [IMG]http://i.imgur.com/csRD2.png[/IMG]
Wait did I seriously give you my entire anti prop minge script?!
You'll need to test it since I'm busy. If it errors let me know. [lua] local function stayoutofplayer(ent, index, radius) if not ent:IsValid() then timer.Destroy(index.."prot") return end for k, v in pairs(ents.FindInSphere(ent:GetPos(), radius)) do if v:IsPlayer() then ent:Remove() end end local vel = ent:GetVelocity() if vel.x<4 and vel.y<4 and vel.z<4 then ent.SafeCount = ent.SafeCount - 1 if ent.SafeCount==0 then ent.NoDamagePhys = nil ent.SafeCount = nil timer.Destroy(index.."prot") end else ent.SafeCount = 5 end end local function addent(ent) timer.Create(ent:EntIndex().."prot", .1, 0, stayoutofplayer, ent, ent:EntIndex(), ent:BoundingRadius( )) ent.NoDamagePhys = true ent.SafeCount = 5 end hook.Add( "PhysgunPickup", "AntiPropPushPickup", function(ply, ent) if not ent:IsPlayer() and ent:GetPhysicsObject():IsValid() then ent:SetCollisionGroup( COLLISION_GROUP_WEAPON ) addent(ent) end end) hook.Add( "OnEntityCreated", "NoDropping", function(ent) if not ent:IsPlayer() and ent:GetPhysicsObject():IsValid() then addent(ent) end end) hook.Add("PhysgunDrop", "AntiPropPushDrop", function(ply, ent) local phys = ent:GetPhysicsObject() if phys:IsValid() and not ent:IsPlayer() then phys:SetVelocity( Vector(0,0,0) ) phys:AddAngleVelocity(ent:GetPhysicsObject():GetAngleVelocity( )*-1) ent:SetCollisionGroup( COLLISION_GROUP_NONE ) addent(ent) end end) hook.Add("EntityTakeDamage", "NoDamageFromFallenProps", function(ply, wep, ent, amm, dmg) if ent.NoDamagePhys or wep.NoDamagePhys then dmg:SetDamage(0) end end) [/lua]
I love you both.
So I'm guessing it works on my first try? Nice.
[QUOTE=thegrb93;37041207]So I'm guessing it works on my first try? Nice.[/QUOTE] I am testing it right now; I went to bed last night, and I just got home. I'll let you know how it goes! Edit: I just tested it, and I spawn with no Physgun or Gravity Gun.
this should work better [lua] local function stayoutofplayer(ent, index, radius) if not ent:IsValid() then timer.Destroy(index.."prot") return end for k, v in pairs(ents.FindInSphere(ent:GetPos(), radius)) do if v:IsPlayer() then ent:Remove() end end local vel = ent:GetVelocity() if vel.x<4 and vel.y<4 and vel.z<4 then ent.SafeCount = ent.SafeCount - 1 if ent.SafeCount==0 then ent.NoDamagePhys = nil timer.Destroy(index.."prot") end else ent.SafeCount = 5 end end local function addent(ent) timer.Create(ent:EntIndex().."prot", .1, 0, stayoutofplayer, ent, ent:EntIndex(), ent:BoundingRadius( )) ent.NoDamagePhys = true ent.SafeCount = 5 end hook.Add( "PhysgunPickup", "AntiPropPushPickup", function(ply, ent) if not ent:IsPlayer() and ent:GetPhysicsObject():IsValid() then ent:SetCollisionGroup( COLLISION_GROUP_WEAPON ) addent(ent) end end) hook.Add( "PlayerSpawnedProp", "NoDropping", function(ply, mdl, ent) addent(ent) end) hook.Add("PhysgunDrop", "AntiPropPushDrop", function(ply, ent) local phys = ent:GetPhysicsObject() if phys:IsValid() and not ent:IsPlayer() then phys:SetVelocity( Vector(0,0,0) ) phys:AddAngleVelocity(ent:GetPhysicsObject():GetAngleVelocity( )*-1) ent:SetCollisionGroup( COLLISION_GROUP_NONE ) addent(ent) end end) hook.Add("EntityTakeDamage", "NoDamageFromFallenProps", function(ply, wep, ent, amm, dmg) if ent.NoDamagePhys or wep.NoDamagePhys then dmg:SetDamage(0) end end) [/lua]
[QUOTE=thegrb93;37042843]this should work better [lua] local function stayoutofplayer(ent, index, radius) if not ent:IsValid() then timer.Destroy(index.."prot") return end for k, v in pairs(ents.FindInSphere(ent:GetPos(), radius)) do if v:IsPlayer() then ent:Remove() end end local vel = ent:GetVelocity() if vel.x<4 and vel.y<4 and vel.z<4 then ent.SafeCount = ent.SafeCount - 1 if ent.SafeCount==0 then ent.NoDamagePhys = nil timer.Destroy(index.."prot") end else ent.SafeCount = 5 end end local function addent(ent) timer.Create(ent:EntIndex().."prot", .1, 0, stayoutofplayer, ent, ent:EntIndex(), ent:BoundingRadius( )) ent.NoDamagePhys = true ent.SafeCount = 5 end hook.Add( "PhysgunPickup", "AntiPropPushPickup", function(ply, ent) if not ent:IsPlayer() and ent:GetPhysicsObject():IsValid() then ent:SetCollisionGroup( COLLISION_GROUP_WEAPON ) addent(ent) end end) hook.Add( "PlayerSpawnedProp", "NoDropping", function(ply, mdl, ent) addent(ent) end) hook.Add("PhysgunDrop", "AntiPropPushDrop", function(ply, ent) local phys = ent:GetPhysicsObject() if phys:IsValid() and not ent:IsPlayer() then phys:SetVelocity( Vector(0,0,0) ) phys:AddAngleVelocity(ent:GetPhysicsObject():GetAngleVelocity( )*-1) ent:SetCollisionGroup( COLLISION_GROUP_NONE ) addent(ent) end end) hook.Add("EntityTakeDamage", "NoDamageFromFallenProps", function(ply, wep, ent, amm, dmg) if ent.NoDamagePhys or wep.NoDamagePhys then dmg:SetDamage(0) end end) [/lua][/QUOTE] That is pretty good, but it is kinda annoying how it just deletes the prop. It also doesn't delete if you spawn a prop above somebody. On the other hand, I like how it deletes the prop, because it prevents abuse on RP servers where people will just phase a prop and walk through it.
Hmm. Does it still allow the prop to kill the player if it is spawned above someone? Should I leave it to delete the prop or is there something else you have in mind?
[QUOTE=thegrb93;37044598]Hmm. Does it still allow the prop to kill the player if it is spawned above someone? Should I leave it to delete the prop or is there something else you have in mind?[/QUOTE] Yes, it still kills the player. What I had in mind was what Derek_SM gave me, I removed the backdoors so it is okay to use.
Sorry, you need to Log In to post a reply to this thread.