i need your help for pixel search

05/03/2021 21:41 sungurcan19#1
This is my pixel search code, the problem is that csgo looks at the place when it sees the pixel in the game.
Code:
search := [[954, 557, 17, 15, 0xC3897C], [957, 559, 6, 5, 0x8D898C]] ; x, y, w, h, color for first & second search
Loop {
 KeyWait, RButton, D
 PixelSearch, x1, y1, search.1.1, search.1.2, search.1.1 + search.1.3 - 1, search.1.2 + search.1.4 - 1
  , search.1.5, 10, Fast RGB
 If ErrorLevel
  Continue
 PixelSearch, x2, y2, search.2.1, search.2.2, search.2.1 + search.2.3 - 1, search.2.2 + search.2.4 - 1
  , search.2.5, 10, Fast RGB
  MouseMove, x1, y1
} Until !ErrorLevel
MouseMove, x1, y1
This code goes to the right destination in in-game pixel search, but sometimes it can go where I don't want it. I can only give the color red in the code below, I want to search for a second color to verify that it is looking like the code above. Or let the code I am submitting looks at the correct korinate in the game.

Code:
#NoEnv
#SingleInstance, Force
#Persistent
#InstallKeybdHook
#UseHook
#KeyHistory, 0
#HotKeyInterval 1
#MaxHotkeysPerInterval 127
version = badeverything v0.02


V::

Pause

Suspend

return


k:: Hotkey, *~$LButton, Toggle


*~$LButton::

SetKeyDelay,-1, 1
SetControlDelay, -1
SetMouseDelay, -1
SetWinDelay,-1
SendMode, InputThenPlay
SetBatchLines,-1
ListLines, Off
CoordMode, Pixel, Screen, RGB
CoordMode, Mouse, Screen
PID := DllCall("GetCurrentProcessId")
Process, Priority, %PID%, High
 
EMCol := 0xF20101
ColVn := 10
AntiShakeX := (A_ScreenHeight // 160)
AntiShakeY := (A_ScreenHeight // 128)
ZeroX := (A_ScreenWidth // 2) ;dont touch?
ZeroY := (A_ScreenHeight // 2) 
CFovX := (A_ScreenWidth // 40)  ;configure for FOV up = smaller lower= bigger current boxes right fov
CFovY := (A_ScreenHeight // 64)
ScanL := ZeroX - CFovX
ScanT := ZeroY
ScanR := ZeroX + CFovX
ScanB := ZeroY + CFovY
NearAimScanL := ZeroX - AntiShakeX
NearAimScanT := ZeroY - AntiShakeY
NearAimScanR := ZeroX + AntiShakeX
NearAimScanB := ZeroY + AntiShakeY

Loop, {
	KeyWait, LButton, D
	PixelSearch, AimPixelX, AimPixelY, NearAimScanL, NearAimScanT, NearAimScanR, NearAimScanB, EMCol, ColVn, Fast RGB
	if (!ErrorLevel=0) {
		loop, 10 {
			PixelSearch, AimPixelX, AimPixelY, ScanL, ScanT, ScanR, ScanB, EMCol, ColVn, Fast RGB
			AimX := AimPixelX - ZeroX
			AimY := AimPixelY - ZeroY
			DirX := -1
			DirY := -1
			If ( AimX > 0 ) {
				DirX := 1
			}
			If ( AimY > 0 ) {
				DirY := 1
			}
			AimOffsetX := AimX * DirX
			AimOffsetY := AimY * DirY
			MoveX := Floor(( AimOffsetX ** ( 1 / 2 ))) * DirX
			MoveY := Floor(( AimOffsetY ** ( 1 / 2 ))) * DirY
			DllCall("mouse_event", uint, 1, int, MoveX * 1.9, int, MoveY, uint, 0, int, 0) ;turing mouse to color were it says * is the speed of the aimbot turn up for unhuman reactions lower for human
		}
	}
}

Pause:: u
return:
goto, init
05/04/2021 11:28 CertainSeller#2
There a lot of pasters :) use unkn0wncheats
05/04/2021 14:21 sungurcan19#3
where :(