SolvedAimbot Broken (Big Newb)

Posts 1–5 of 5 · Page 1 of 1
Aimbot Broken (Big Newb)
Code:
hook.Add("CreateMove", "Aimbot", function(CUserCmd)
    
    for k,v in pairs ( player.GetAll() ) do
        
        local aimat = ( v:GetPos() )
        
        if v == LocalPlayer() then aimat = "" else aimat = v:GetPos() end
        
        local ply = LocalPlayer()
        local trace = util.GetPlayerTrace( v ) 
        local traceRes = util.TraceLine( trace )
        if traceRes.HitNonWorld then 
            if v:IsPlayer() then
                local targethead = v:LookupBone("ValveBiped.Bip01_Head1") 
                local targetheadpos = v:GetBonePosition(targethead) 
                CUserCmd:SetViewAngles((targetheadpos - ply:GetShootPos()):Angle())
            end
        end
    end
end)
Anybody help? The aimbot randomly aims at people through walls and is extremely shakey.
Quote Originally Posted by poonystalker View Post
Code:
hook.Add("CreateMove", "Aimbot", function(CUserCmd)
	
	for k,v in pairs ( player.GetAll() ) do
		
		local aimat = ( v:GetPos() )
		
		if v == LocalPlayer() then aimat = "" else aimat = v:GetPos() end
		
		local ply = LocalPlayer()
		local trace = util.GetPlayerTrace( v ) 
		local traceRes = util.TraceLine( trace )
		if traceRes.HitNonWorld then 
			if v:IsPlayer() then
				local targethead = v:LookupBone("ValveBiped.Bip01_Head1") 
				local targetheadpos = v:GetBonePosition(targethead) 
				CUserCmd:SetViewAngles((targetheadpos - ply:GetShootPos()):Angle())
			end
		end
	end
end)
Anybody help? The aimbot randomly aims at people through walls and is extremely shakey.
ur getting trace for wrong person, get the trace for yourself
or !v:Alive()
or v:Health() < 1
I hope you realize The Alive check is %100 slow compared to health,
Quote Originally Posted by 2cashs View Post
I hope you realize The Alive check is %100 slow compared to health,
I was informed of this and corrected it. I also added a toggleable team check.
Quote Originally Posted by poonystalker View Post
I was informed of this and corrected it. I also added a toggleable team check.
Here, this should help you a bit with things.
if(v == me || v:IsDormant() || eHealth(v) < 1) then continue; end
if(DreamBot.Config["Aimbot"]["GhostCheck"] && v:GetColor().a != 255) then continue; end
if(!DreamBot.Config["Aimbot"]["targetteam"] && !DreamBot.Config["Aimbot"]["onlytargetteam"] && pTeam(me) == pTeam(v)) then continue; end
if (DreamBot.Config["Aimbot"]["onlytargetteam"] && pTeam(v) != pTeam(me)) then continue; end
if(!DreamBot.Config["Aimbot"]["targetfriends"] && pGetFriendStatus(v) == "friend") then continue; end
Posts 1–5 of 5 · Page 1 of 1
This thread is closed for replies.

Similar Threads

Tags for this Thread

None

Talk with us