All I did was fix the 'Aimbot' in it since people kept using it against me, and there's still no fix around.
Just extract it into /addons/, or replace it with your current Smart-Snap.
What it does:
Before fix, you could snap onto other players with it, and it counted as a aimbot (It was kinda OP).
Fixed:
Stops you snapping onto other players.
Download:
[url=http://puu.sh/fT5Pv.7z]Click me[/url]
Forgot to add:
I searched around google for a fix before I posted this, (I may be bad at searching though, I didn't care that much).
Can you post the source?
[QUOTE=Quark:;47137423]Can you post the source?[/QUOTE]
Please tell me that you are joking
No dude that lua file is compiled by the visual studio 2012 conpiliation interface licened by Microsoft corperation 2012® All rights reserved reading this post means you are willingly accepting our TOS (See Section 5c) and we reserve the right to upload any files on your personal computer for further analysis.
[editline]15th February 2015[/editline]
Any and all attempts to reverse engineer or otherwise dissect this post will be punishable by United States law.
Not yet. I am currently finishing a summer job before starting back at university. Did you have some ideas?
_______________________
sara
[highlight](User was permabanned for this post ("Bot" - Craptasket))[/highlight]
[QUOTE=zuneera;47163049]Not yet. I am currently finishing a summer job before starting back at university. Did you have some ideas?
_______________________
sara[/QUOTE]
What?
I'm having a hard time evaluating this situation.
I don't know whats happening either.. No source, No DL.
[QUOTE=AustinH;47170748]I don't know whats happening either.. No source, No DL.[/QUOTE]
uhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhh
GLua isn't obfuscated.
Here's the 'SOURCE' you are all looking for because this is obfuscated apparently.
[code]
--[[
Fixed by Pawsative,
Sorry kids who couldn't use l33t hacks and had to use this exploit :(
]]--
if SERVER then
AddCSLuaFile( "smartsnap.lua" )
resource.AddFile( "materials/smartsnap_offsets_default.png" )
end
local target = { active = false }
local snaptarget = { active = false }
local snapkey = false
local snaptime = false
local snaplock = false
local snapclick = false
local snapclickfade = 0
local snapcursor = false
local snapspawnmenu = false
local cache = {
vPlayerPos = 0,
vLookPos = 0,
vLookClipPos = 0,
vLookVector = 0,
}
local condefs = {
snap_enabled = 1,
snap_gcboost = 1,
snap_gcstrength = 125,
snap_hidegrid = 0,
snap_clickgrid = 0,
snap_toggledelay = 0,
snap_disableuse = 0,
snap_allentities = 0,
snap_alltools = 0,
snap_enabletoggle = 0,
snap_lockdelay = 0.5,
snap_distance = 250,
snap_gridlimit = 16,
snap_gridsize = 8,
snap_gridalpha = 0.4,
snap_gridoffset = 0.5,
snap_boundingbox = 1,
snap_revertaim = 1,
snap_centerline = 1,
}
local convars = {}
for key,value in pairs(condefs) do
convars[#convars + 1] = key
end
local modelsaveset = {}
local modeloffsets = {}
---------
local function DrawScreenLine(vsA, vsB)
surface.DrawLine(vsA.x, vsA.y, vsB.x, vsB.y)
end
local function ToScreen(vWorld)
local vsScreen = vWorld:ToScreen()
return Vector(vsScreen.x, vsScreen.y, 0)
end
local function PointToScreen(vPoint)
if cache.vLookVector:DotProduct(vPoint - cache.vLookClipPos) > 0 then
return ToScreen(vPoint)
end
end
local function LineToScreen(vStart, vEnd)
local dotStart = cache.vLookVector:DotProduct(vStart - cache.vLookClipPos)
local dotEnd = cache.vLookVector:DotProduct(vEnd - cache.vLookClipPos)
if dotStart > 0 and dotEnd > 0 then
return ToScreen(vStart), ToScreen(vEnd)
elseif dotStart > 0 or dotEnd > 0 then
local vLength = vEnd - vStart
local vIntersect = vStart + vLength * ((cache.vLookClipPos:DotProduct(cache.vLookVector) - vStart:DotProduct(cache.vLookVector)) / vLength:DotProduct(cache.vLookVector))
if dotStart <= 0 then
return ToScreen(vIntersect), ToScreen(vEnd)
else
return ToScreen(vStart), ToScreen(vIntersect)
end
end
end
local function RayQuadIntersect(vOrigin, vDirection, vPlane, vX, vY)
local vp = vDirection:Cross(vY)
local d = vX:DotProduct(vp)
if (d <= 0.0) then return end
local vt = vOrigin - vPlane
local u = vt:DotProduct(vp)
if (u < 0.0 or u > d) then return end
local v = vDirection:DotProduct(vt:Cross(vX))
if (v < 0.0 or v > d) then return end
return Vector(u / d, v / d, 0)
end
------------
local function OnInitialize()
for key,value in pairs(condefs) do
CreateClientConVar(key, value, true, false)
end
for _,filename in ipairs(file.Find('smartsnap_offsets_*.png', "GAME")) do
local file = file.Read(filename)
if file then
lines = string.Explode("\n", file)
header = table.remove(lines, 1)
if header == "SMARTSNAP_OFFSETS" then
for _,line in ipairs(lines) do
local pos = string.find(line, '=')
if pos then
local key = string.lower(string.Trim(string.sub(line, 1, pos - 1)))
local value = string.Trim(string.sub(line, pos + 1))
local c = string.Explode(",", value)
modeloffsets[key]= { tonumber(c[1]), tonumber(c[2]), tonumber(c[3]), tonumber(c[4]), tonumber(c[5]), tonumber(c[6]) }
end
end
end
end
end
end
local function OnShutDown()
output = file.Read('smartsnap_offsets_custom.png')
if output == nil then
output = "SMARTSNAP_OFFSETS\n"
end
for model,_ in pairs(modelsaveset) do
output = output .. model .. '=' .. table.concat(modeloffsets[model], ",") .. "\n"
end
file.Write('smartsnap_offsets_custom.png', output)
end
local function GetDevOffset()
local model = string.lower(target.entity:GetModel())
if modeloffsets[model] == nil then
modeloffsets[model] = { 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 }
end
return modeloffsets[model]
end
concommand.Add("snap_dev_alloffset", function(player, command, arguments) if target.active == true then if #arguments >= 1 then local v = GetDevOffset() for i=1,6 do v[i] = v[i] + tonumber(arguments[1]) end end end end)
concommand.Add("snap_dev_gridoffset", function(player, command, arguments) if target.active == true then if #arguments >= 1 then local v = GetDevOffset() v[target.face] = v[target.face] + tonumber(arguments[1]) end end end)
concommand.Add("snap_dev_saveoffset", function(player, command, arguments) if target.active == true then local v = GetDevOffset() modelsaveset[string.lower(target.entity:GetModel())] = true end end)
local function SnapToggleGrid()
if (GetConVarNumber("snap_enabled") == 0) then
RunConsoleCommand('snap_enabled', '1')
else
RunConsoleCommand('snap_enabled', '0')
end
end
local function SnapPress()
if GetConVarNumber("snap_clickgrid") != 0 and !snapclick then
snapclick = true
snapclickfade = CurTime()
elseif GetConVarNumber("snap_clickgrid") == 0 or snapclick then
if (snaplock or snapcursor) then
snaptime = false
else
local toggledelay = GetConVarNumber("snap_toggledelay")
if (toggledelay > 0 and snaptime and snaptime + toggledelay > CurTime()) then
SnapToggleGrid()
snaptime = false
snaplock = false
else
snaptime = CurTime()
end
end
snapkey = target.active
if (!snapcursor) then
snaplock = false
end
end
end
local function SnapRelease()
snapkey = false
end
local function SnapLock()
snaplock = !snaplock
end
local function OnSpawnMenu()
snapspawnmenu = true
end
//CHECK OUT MY MIXTAPE SOUNDCLOUD.COM/PAWSATIVE
local function OnKeyPress(player, key)
if (key == IN_USE and GetConVarNumber("snap_disableuse") == 0) then
SnapPress()
end
end
local function OnKeyRelease(player, key)
if (key == IN_USE and GetConVarNumber("snap_disableuse") == 0) then
SnapRelease()
end
end
local function OnThink()
if (vgui.CursorVisible()) then
if (!snapcursor and snaplock) then
snaptarget = table.Copy(target)
end
snaptime = false
snapcursor = true
else
if (snapcursor and snaplock) then
target = snaptarget
end
snapspawnmenu = false
snapcursor = false
end
if (GetConVarNumber("snap_enabletoggle") != 0) then
if (snapkey and snaptime and !snaplock) then
if (CurTime() > snaptime + GetConVarNumber("snap_lockdelay")) then
snaplock = true
snaptime = false
end
end
end
local locked = target.locked and target.active
target.locked = (snapkey or snaplock and !snapcursor) and target.active
if (!target.locked and locked and GetConVarNumber("snap_revertaim") != 0) then
if (snapcursor) then
local screen = target.entity:LocalToWorld(target.vector):ToScreen()
gui.SetMousePos(math.Round(screen.x), math.Round(screen.y))
else
local angles = (target.entity:LocalToWorld(target.vector) - LocalPlayer():GetShootPos()):Angle()
LocalPlayer():SetEyeAngles(angles)
end
end
end
local function CalculateGridAxis(L)
local length = L:Length()
local grid = math.Clamp(math.floor(length / (2 * GetConVarNumber("snap_gridsize"))) * 2, 2, GetConVarNumber("snap_gridlimit"))
local offset = math.Clamp(GetConVarNumber("snap_gridoffset") / length, 0, 1 / grid)
local scale = 1 - offset * 2
return {
length = length,
offset = offset,
scale = scale,
grid = grid,
}
end
local function CalculateSnap(X, Y, v)
local LX = CalculateGridAxis(X)
local LY = CalculateGridAxis(Y)
local BX = math.Clamp(math.Round(v.x * LX.grid), 0, LX.grid)
local BY = math.Clamp(math.Round(v.y * LY.grid), 0, LY.grid)
if BX == 1 and v.x < (1 / LX.grid + LX.offset) / 2 then BX = 0 end
if BX == LX.grid - 1 and v.x > 1 - (1 / LX.grid + LX.offset) / 2 then BX = LX.grid end
if BY == 1 and v.y < (1 / LY.grid + LY.offset) /
Sorry, you need to Log In to post a reply to this thread.