• Having random server crashes? Could be stacker related
    2 replies, posted
I have noticed there were 6 related crashes on my RP server today. My server has stacker and precision and a while back a member of my community told me that there was an "exploit" (or whatever you wanna call it) that would allow you to crash the server with the Stacker tool. How? Simple, just enter a really big number in the Offset * text fields. After doing that, stack a prop and you're away. All the physics will go all spazzy and all props will start falling through the ground until the server crashes. I noticed when the physics broke, an instant crash could be achieved by simply using the precision tool. There is already a fix hanging around that was given to me by a community member (hes not a coder so I assume he got it off FP or something) which didnt work. It involved using math.Clamp on line 89 or something like that to limit the numbers like so: [CODE] local OffsetX = math.Clamp(self:GetClientNumber( "offsetx" ), -300, 300) local OffsetY = math.Clamp(self:GetClientNumber( "offsety" ), -300, 300) local OffsetZ = math.Clamp(self:GetClientNumber( "offsetz" ), -300, 300)[/CODE] That didnt work for me. I could still exceed the supposed 300 limit. So I looked for the variables OffsetX, OffsetY & OffsetZ in the TOOL:StackerCalcPos function. I notice the Offset variables were in this function, so I decided to clamp them at some sort of far fetched attempt to fix it. Doing this fixed my problem completely! If youd like to perform this fix yourself, simply replace the TOOL:StackerCalcPos function with this code: [CODE] function TOOL:StackerCalcPos(lastent, mode, dir, offset) local forward = Vector(1,0,0):Angle() local pos = lastent:GetPos() local ang = lastent:GetAngles() local lower, upper = lastent:WorldSpaceAABB( ) local glower = lastent:OBBMins() local gupper = lastent:OBBMaxs() local stackdir = Vector(0,0,1) local height = math.abs(upper.z - lower.z) if mode == 1 then // Relative to world if dir == 1 then stackdir = forward:Up() height = math.abs(upper.z - lower.z) elseif dir == 2 then stackdir = forward:Up() * -1 height = math.abs(upper.z - lower.z) elseif dir == 3 then stackdir = forward:Forward() height = math.abs(upper.x - lower.x) elseif dir == 4 then stackdir = forward:Forward() * -1 height = math.abs(upper.x - lower.x) elseif dir == 5 then stackdir = forward:Right() height = math.abs(upper.y - lower.y) elseif dir == 6 then stackdir = forward:Right() * -1 height = math.abs(upper.y - lower.y) end elseif mode == 2 then // Relative to prop forward = ang if dir == 1 then stackdir = forward:Up() offset = forward:Up() * math.Clamp(offset.x, -300, 300) + forward:Forward() * -1 * math.Clamp(offset.z, -300, 300) + forward:Right() * math.Clamp(offset.y, -300, 300) height = math.abs(gupper.z - glower.z) elseif dir == 2 then stackdir = forward:Up() * -1 offset = forward:Up() * -1 * math.Clamp(offset.x, -300, 300) + forward:Forward() * math.Clamp(offset.z, -300, 300) + forward:Right() * math.Clamp(offset.y, -300, 300) height = math.abs(gupper.z - glower.z) elseif dir == 3 then stackdir = forward:Forward() offset = forward:Forward() * math.Clamp(offset.x, -300, 300) + forward:Up() * math.Clamp(offset.z, -300, 300) + forward:Right() * math.Clamp(offset.y, -300, 300) height = math.abs(gupper.x - glower.x) elseif dir == 4 then stackdir = forward:Forward() * -1 offset = forward:Forward() * -1 * math.Clamp(offset.x, -300, 300) + forward:Up() * math.Clamp(offset.z, -300, 300) + forward:Right() * -1 * math.Clamp(offset.y, -300, 300) height = math.abs(gupper.x - glower.x) elseif dir == 5 then stackdir = forward:Right() offset = forward:Right() * math.Clamp(offset.x, -300, 300) + forward:Up() * math.Clamp(offset.z, -300, 300) + forward:Forward() * -1 * math.Clamp(offset.y, -300, 300) height = math.abs(gupper.y - glower.y) elseif dir == 6 then stackdir = forward:Right() * -1 offset = forward:Right() * -1 * math.Clamp(offset.x, -300, 300) + forward:Up() * math.Clamp(offset.z, -300, 300) + forward:Forward() * math.Clamp(offset.y, -300, 300) height = math.abs(gupper.y - glower.y) end end //offset = (stackdir:Angle():Up() * math.Clamp(offset.z, -300, 300)) + (stackdir:Angle():Forward() * math.Clamp(offset.x, -300, 300)) + (stackdir:Angle():Right() * math.Clamp(offset.y, -300, 300)) return stackdir, height, offset end[/CODE] This worked for me. Let me know if theres anything im missing.
nice work pete tis looking well
This has nothing to do with the Stacker tool, but there are a few exploiters going around who are able to crash servers at will, and also allow themselves to noclip and spawn weapons. They've done it to my server, and have what seems to be an infinite amount of alternate Steam accounts, so they're virtually unbannable.
Sorry, you need to Log In to post a reply to this thread.