LightbulbNk Check Pixel

Posts 1–2 of 2 · Page 1 of 1
Nk Check Pixel
Pixel Checker

Disclaimer :
This tool is used with the Adventure Bot : https://www.mpgh.net/forum/showthread.php?t=1490847
It is only working on trove on primary monitor.

Info & Tuto :

To make it work :
  • Press "i" and disable everything except "Dungeons".
  • Then set the game to windowed mode.
  • Maximize this window.
  • Find one or more dungeons ingame.
  • Open your character page.
  • Start the tool from the GUI or directly from the file.
  • Bring your cursor to the middle of the dungeon star.
  • Press 1 to pause the script and automatically copy these values
  • Replace the ones in the code with those you just copied
    Code:
    Dungeon1 := PixelColorSimple(1560, 122, hWnd) <- Here are the first 2 values
    Dungeon2 := PixelColorSimple(1560, 194, hWnd) <- Same here with vertical offset
    Dungeon3 := PixelColorSimple(1560, 266, hWnd) <- And here too
    if (Dungeon1 = "0xFEF89A"||Dungeon2 = "0xFEF89A"||Dungeon3 = "0xFEF89A")<- And here are the color codes
  • if you want to detect multiple dungeons, find a 3* dungeon and repeat with each dungeon :



Feel free to comment with your resolution and a working combination of "X, Y, Color" to help others !

AHK Script :
Code:
CoordMode, Mouse, Screen
CoordMode, Pixel, Screen

loop
{
	MouseGetPos X, Y 
	PixelGetColor Color, %X%, %Y%, RGB
	ToolTipColor(Color, "Black")
	ToolTip,  X : %X%   Y : %Y%   Resolution : %A_ScreenWidth%x%A_ScreenHeight%   Color : %Color%`n Press num1 to pause and copy values`nPress num0 to exit
}
;Hotkeys
Numpad1::
	if(!IsPaused){
		IsPaused := 1
		Clipboard := X . ";" . Y . " " . Color
		MsgBox, Coords/PixelColor copied
	}else{
		IsPaused := 0
	}
	Pause,,1 
Return
Numpad0::ExitApp


;libraries :

;Thanks to lexikos for his tooltip color lib
ToolTipColor(Background := "", Text := "", hwnd := "") {
    static bc := "", tc := ""
    if (hwnd = "") {
        if (Background != "")
            bc := Background="Default" ? "" : _TTG("Color", Background)
        if (Text != "")
            tc := Text="Default" ? "" : _TTG("Color", Text)
        _TTHook()
    }
    else {
        VarSetCapacity(empty, 2, 0)
        DllCall("UxTheme.dll\SetWindowTheme", "ptr", hwnd, "ptr", 0
            , "ptr", (bc != "" && tc != "") ? &empty : 0)
        if (bc != "")
            DllCall("SendMessage", "ptr", hwnd, "uint", 1043, "ptr", bc, "ptr", 0)
        if (tc != "")
            DllCall("SendMessage", "ptr", hwnd, "uint", 1044, "ptr", tc, "ptr", 0)
    }
} 
_TTHook() {
    static hook := 0
    if !hook
        hook := DllCall("SetWindowsHookExW", "int", 4
            , "ptr", RegisterCallback("_TTWndProc"), "ptr", 0
            , "uint", DllCall("GetCurrentThreadId"), "ptr")
} 
_TTWndProc(nCode, _wp, _lp) {
    Critical 999
   ;lParam  := NumGet(_lp+0*A_PtrSize)
   ;wParam  := NumGet(_lp+1*A_PtrSize)
    uMsg    := NumGet(_lp+2*A_PtrSize, "uint")
    hwnd    := NumGet(_lp+3*A_PtrSize)
    if (nCode >= 0 && (uMsg = 1081 || uMsg = 1036)) {
        _hack_ = ahk_id %hwnd%
        WinGetClass wclass, %_hack_%
        if (wclass = "tooltips_class32") {
            ToolTipColor(,, hwnd)
        }
    }
    return DllCall("CallNextHookEx", "ptr", 0, "int", nCode, "ptr", _wp, "ptr", _lp, "ptr")
} 
_TTG(Cmd, Arg1, Arg2 := "") {
    static htext := 0, hgui := 0
    if !htext {
        Gui _TTG: Add, Text, +hwndhtext
        Gui _TTG: +hwndhgui +0x40000000
    }
    Gui _TTG: %Cmd%, %Arg1%, %Arg2%
    if (Cmd = "Font") {
        GuiControl _TTG: Font, %htext%
        SendMessage 0x31, 0, 0,, ahk_id %htext%
        return ErrorLevel
    }
    if (Cmd = "Color") {
        hdc := DllCall("GetDC", "ptr", htext, "ptr")
        SendMessage 0x138, hdc, htext,, ahk_id %hgui%
        clr := DllCall("GetBkColor", "ptr", hdc, "uint")
        DllCall("ReleaseDC", "ptr", htext, "ptr", hdc)
        return clr
    }
}
Virus scans :
https://virusscan.jotti.org/filescanjob/zyt0tv3n8l
https://www.virustotal.com/gui/file/...852d/detection
NkPxChk_mpgh.net.rar1 KB · 8 downloads Clean
/approved //2short//
Posts 1–2 of 2 · Page 1 of 1
This thread is closed for replies.

Similar Threads

Tags for this Thread

None

Need help?