Hello, I'm trying to figure out how to make a simple triggerbot that clicks when it finds a certain color within a box but I'm not sure how to make it click when it finds the color.
For example, I want to make it shoot when the crosshair is green and I want to make it search within this box I made:
The script I have so far is
Quote:
While 1
PixelSearch ( 925, 505, 994, 573, 0x42BB1B, 10 )
if Not @error Then
MouseClick("left")
EndIf
WEnd
I'm new to autoit and I'm not really sure what I should do.
I'm still fairly new myself. Is this what you are asking for?
Code:
Local $coord = PixelSearch(0, 0, 50, 50, 0xFFFFFF) ;Left, top, right, bottom, color
If Not @error Then
Send("{1}") ;It found the color so it does this
ElseIf @error Then
Send("{0}") ;It didn't find the color so it does this
EndIf
To get it to do exactly what you're asking... I'd do this (although I'm sure my script is sloppy):
Code:
Shoot()
Func Shoot()
While 1
Local $coord = PixelSearch(848, 447, 1054, 617, 0x42BB1B, 10)
If Not @error Then
MouseClick("Left") ;It found the color so it does this
Sleep(10)
ElseIf @error Then
Sleep(10)
Shoot() ;It didn't find the color so it does this
EndIf
WEnd
EndFunc ;==>Shoot
Edit: I tried it and my game started to lag. I added in the sleep(10) and it seems to work fine now.
I think that second script will work... It's set to loop until you exit the script.
If it doesn't find the color it'll redo the search. Assuming it works, of course. I might have to try it out next time I play APB:R.
Hello, I'm trying to figure out how to make a simple triggerbot that clicks when it finds a certain color within a box but I'm not sure how to make it click when it finds the color.
For example, I want to make it shoot when the crosshair is green and I want to make it search within this box I made:
The script I have so far is
I'm new to autoit and I'm not really sure what I should do.
you must define pixelsearch as a variable
look in the autoit help:
Code:
; Find a pure red pixel in the range 0,0-20,300
Local $coord = PixelSearch(0, 0, 20, 300, 0xFF0000)
If Not @error Then
MsgBox(0, "X and Y are:", $coord[0] & "," & $coord[1])
mouseclick("left")
EndIf
; Find a pure red pixel or a red pixel within 10 shades variations of pure red
$coord = PixelSearch(0, 0, 20, 300, 0xFF0000, 10)
If Not @error Then
MsgBox(0, "X and Y are:", $coord[0] & "," & $coord[1])
EndIf
I think that second script will work... It's set to loop until you exit the script.
If it doesn't find the color it'll redo the search. Assuming it works, of course. I might have to try it out next time I play APB:R.
It works but it has a delay, it will randomly shoot sometimes (I know that's because it's finding the color it needs but even when I'm aiming on a player, it sometimes will shoot but mostly wont or not nearly close to the right time) but thanks anyways.
It works but it has a delay, it will randomly shoot sometimes (I know that's because it's finding the color it needs but even when I'm aiming on a player, it sometimes will shoot but mostly wont or not nearly close to the right time) but thanks anyways.
I would guess that you need to confine your pixelsearch range to a smaller scope. If you set the search range to JUST around your crosshairs, it should work perfectly.
I can't do that for you since it's your game.
Code:
Func Shoot()
While 1
Local $coord = PixelSearch([B]848, 447, 1054, 617[/B], 0x42BB1B, 10)
If Not @error Then
MouseClick("Left") ;It found the color so it does this
Sleep(10)
ElseIf @error Then
Sleep(10)
Shoot() ;It didn't find the color so it does this
EndIf
WEnd
EndFunc ;==>Shoot
I bolded the coordinates that define your search area.
Also, try messing with the color variation in the pixelsearch. (It's the 10 at the end.)
Oh and, that pixelcolor I put in the script... It's the one you had. I think you took a green color. Try using: 0xBA0714
That's the red color the crosshairs go to when you aim at a player...
I bolded the coordinates that define your search area.
Also, try messing with the color variation in the pixelsearch. (It's the 10 at the end.)
Oh and, that pixelcolor I put in the script... It's the one you had. I think you took a green color. Try using: 0xBA0714
That's the red color the crosshairs go to when you aim at a player...
Yeah I know, the green was just to test if it worked but I had already changed it to red. What do you recommend the shades being at? My resolution is 1920x1080 and that's what I play my game in, so i'm not sure what the box should be.
Yeah I know, the green was just to test if it worked but I had already changed it to red. What do you recommend the shades being at? My resolution is 1920x1080 and that's what I play my game in, so i'm not sure what the box should be.
When you're in the game press ALT+ENTER to go into windowed mode. Once you're in there use the autoit window info to get the coordinates just around your crosshair.
I've got it working and everything but I think it's a little late on response occasionally because I'm dropping about 20-30fps, any ideas why it's causing this much lag?
Code:
Shoot()
Func Shoot()
While 1
Local $coord = PixelSearch(926, 475, 987, 535, 0xBA0714, 30)
If Not @error Then
MouseClick("Left")
EndIf
WEnd
EndFunc ;==>Shoot
Is there anywhere I should add sleeps or something? I also have to play it in windowed mode or it won't work even running as x64, help on this would be cool too.
I've got it working and everything but I think it's a little late on response occasionally because I'm dropping about 20-30fps, any ideas why it's causing this much lag?
Code:
Shoot()
Func Shoot()
While 1
Local $coord = PixelSearch(926, 475, 987, 535, 0xBA0714, 30)
If Not @error Then
MouseClick("Left")
[B] Sleep(100)[/B]
EndIf
WEnd
EndFunc ;==>Shoot
Is there anywhere I should add sleeps or something? I also have to play it in windowed mode or it won't work even running as x64, help on this would be cool too.
Without that sleep there it'll cause your FPS to drop, so mess around with it. Sleep(100) may or may not work for you.
To make it work fullscreen... Not sure, I always use scripts in windowed mode on games. Try messing with @DesktopWidth and @DesktopHeight
im on a 1980x1080
the scan box i am looking for is smaller basically the top tick on the crosshair and its width. allowing enough length for bloom or larger static cross haired weapons
the box i am trying to hit as example is
965, 525, 955, 540, (based off of the png screen shot at full screen)
with colour 0x0BOCC4 (based off of the png screen shot at full screen)
Triggerbot 05/29/2012 - WarRock Hacks, Bots, Cheats & Exploits - 9 Replies Sorry wenn das schonmal gefragt wurde, aber was macht eigl. dieser Triggerbot?
Need cs1.6 triggerbot 03/25/2012 - Counter-Strike - 1 Replies hi guys can anyone share me a cs 1.6 triggerbot thank you ^^
CSS Triggerbot 1.6.1 03/20/2012 - Counter-Strike Hacks, Bots, Cheats & Exploits - 6 Replies Hello guys, i wanted to share my extern CSS/Cs1.6 Triggerbot, its coded in C++.
Its not opensource, but its free to use for everyone.
Its Undetected by all AC's at the moment. DBL Checked it, so yea im sure.
Aimbot undedectet.
Knife with new design.
Triggerbot? 09/04/2010 - Counter-Strike - 2 Replies hallo liebe community
gibt es den GARKEIN css hack oder script mit triggerbot?
brauche sehr dringend einen würde dafür sogar einen server sponsern!