Jump to content

Aimbot


 Share

Recommended Posts

Hey, I'm trying to make a aimbot, but it doesn't work.

hotkeyset("{f1}","stop")
hotkeyset("{f2}","pause")
$color=0xFF0000
$pause=false

while 1
    $head_search=PixelSearch(0,0,1280,1024,$color,5,1)
    if $head_search= not @error then
        MouseClick ("left",$head_search[0],$head_search[1],1,1)
    EndIf
    sleep (5)
WEnd

func stop ()
    Exit
EndFunc

func pause()
    $pause=not $pause
    if $pause=true Then
        Do
            sleep (5)
        until $pause=False
    EndIf
EndFunc

I don't know what to do.

Link to comment
Share on other sites

and im not so sure about this

yours if $head_search= not @error then

should be if @error then ; you already declared what headsearch was.

your pause function isnt lookin quite right either do you write your stuff in scite it has a syntax checker.

Edited by Seagul
Link to comment
Share on other sites

  • 2 weeks later...

but i kinda have a better version use this perfect base...

; Find a pure red pixel in the range 0,0-20,300
Opt("MustDeclareVars", 0)
local $pause
HotKeySet("+!d", "main")  ;Shift-Alt-d
HotKeySet("{PAUSE}", "Pause")
HotKeySet("{ESC}", "Terminate")
While 1
    Sleep(100)
WEnd

func main()
while 1
$CoOrd = PixelSearch(400, 300, 600, 400, 0xff0000, 20)   ; Looks for colour 0xff0000.
If Not @error Then ;If it exists then
MouseClick("Left", $CoOrd[0], $CoOrd[1], 1, 0) ;Clicks the first instance of that colour
else
EndIf
wend
endfunc

Func Pause()
   $pause=not $pause
    if $pause=true Then
        Do
            sleep (5)
        until $pause=False
    EndIf
        ToolTip('Script is "Paused"',0,0)
    ToolTip("")
EndFunc

Func Terminate()
    Exit 0
EndFunc
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...