
badcoder123
Active Members-
Posts
78 -
Joined
-
Last visited
Recent Profile Visitors
The recent visitors block is disabled and is not being shown to other users.
badcoder123's Achievements

Wayfarer (2/7)
5
Reputation
-
badcoder123 reacted to a post in a topic: How can I edit "New AutoIt v3 Script" template?
-
Is it possible for the bot to receive images/videos? The Polling function detects it but not sure if it's even possible... Sample While 1 $msgData = _Polling() _ArrayDisplay($msgData) $data = $msgData[5] ConsoleWrite($data & @CRLF) _SendMsg($ChatID, "Your message was: " & $data) WEnd
- 111 replies
-
badcoder123 reacted to a post in a topic: Script becomes way slower after a msgbox - (Moved)
-
This section. How can we help?
-
badcoder123 reacted to a post in a topic: Ballot Paper Analyzer
-
#include <AutoItConstants.au3> HotKeySet("{esc}", "Loop") $looping = 0 Loop() While 1 ConsoleWrite("Searching" & @LF) $coord = PixelSearch(0, 0, 100, 200, 0xB200) If Not @error Then MouseClick($MOUSE_CLICK_LEFT, $coord[0], $coord[1], 2, 1) MsgBox(0, " Clicked at X:", $coord[0] & "and Y:" & $coord[1]) EndIf WEnd Func Loop() $looping = Not $looping ConsoleWrite("Paused" & @LF) While $looping Sleep(200) WEnd EndFunc ;==>Loop
-
badcoder123 reacted to a post in a topic: shake a window
-
Modify this so it's a quick circle $pi = 4 * ATan(1) $centerX = @DesktopWidth / 2 $centerY = @DesktopHeight / 2 $RMax = @DesktopHeight / 2 $R = 0 While 1 For $i = 0 To 2 * $pi Step 0.03125 WinMove("Untitled - Notepad", "", $centerX + ($R * Cos($i)), $centerY + ($R * Sin($i))) $R += 0.5 If $R > $RMax Then $R = 0 Sleep(10) Next WEnd
-
{pause} command messing when running 2 scripts
badcoder123 replied to Typical-User's topic in AutoIt General Help and Support
are they on the same hotkey? switch them up per script -
I believe Nox only uses 1 control for its emulation (control bar, window options being different) so this would work for its base control if you +posx and +posy for the window borders. Not certain but I'm believe it does only has one control
-
badcoder123 reacted to a post in a topic: WM_Mousemove not moving
-
#include <WinAPIGdiDC.au3> #include <SendMessage.au3> $hWnd = WinWait("Untitled - Paint") $hControl = ControlGetHandle($hWnd, "", "Afx:00007FF78D1E0000:81") Func Mousedrag($x1, $y1, $x2, $y2) Local $WM_MOUSEMOVE = 0x0200 Local $MK_LBUTTON = 0x0001 Local $WM_LBUTTONDOWN = 0x0201 Local $WM_LBUTTONUP = 0x0202 _SendMessage($hControl, $WM_MOUSEMOVE, 0, _WinAPI_MakeLong($x1, $y1)) _SendMessage($hControl, $WM_LBUTTONDOWN, $MK_LBUTTON, _WinAPI_MakeLong($x1, $y1)) _SendMessage($hControl, $WM_MOUSEMOVE, 0, _WinAPI_MakeLong($x2, $y2)) _SendMessage($hControl, $WM_LBUTTONUP, $MK_LBUTTON, _WinAPI_MakeLong($x2, $y2)) EndFunc ;==>Mousedrag Mousedrag(484, 554, 732, 554) ConsoleWrite($hWnd & @LF & $hControl & @LF) Coords relevant to the control
-
Local $Putincart= 0 Local $Startdig= 0 Do $Startdig= $Startdig+1 $Putincart= $Putincart+1 Until $Putincart = 14 And $Startdig = 1 how does $Startdig ever = 1 and $Putincart = 14 at the same time?
-
Made this function and modified it Func _ColourReturn($x, $y, $colour) If PixelGetColor($x, $y, $hWnd) = $colour Then Return True If PixelGetColor($x, $y, $hWnd) <> $colour Then Return False EndFunc Try this out. Just set a sleep delay in the do loop Const $pixel_check_x = 1030 Const $pixel_check_y = 409 Const $pixel_check_color = 13093063 Const $send_delay_ms = 520 Const $iStaticSleep = xxxxxxxxxxxxxxxx Do Sleep($iStaticSleep) Until _ColourReturn($pixel_check_x, pixel_check_y, $pixel_check_color) Sleep($send_delay_ms) Send("{SPACE}") Exit Func _ColourReturn($x, $y, $colour) If PixelGetColor($x, $y) = $colour Then Return True If PixelGetColor($x, $y) <> $colour Then Return False EndFunc
-
badcoder123 reacted to a post in a topic: killerbee123https://www.autoitscript.com/forum/topic/197199-killerbee123/
-
badcoder123 reacted to a post in a topic: Image Search help
-
badcoder123 reacted to a post in a topic: UIASpy - UI Automation Spy Tool
-
Hey, All! I was looking into the help file at all the drawing utilities and I was wondering if you draw a translucent line that follows your cursor. Upon looking for ideas I came across this thread (1.0) and saw UEZ's response. I also came across another post that UEZ replied to and found this reply (1.1) where he shows how you can draw on the desktop. This is what I'm looking for however I'd still like to be able to interact with a designated application and have the line/curve/vector passively follow it. Obviously we don't move our cursor very linearly so it would have to be able to draw on vectors. Am I over complicating this? Any ideas or starting points I should look more into? 1.0 #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> Global Const $aFullScreen = WinGetPos(WinGetHandle("[TITLE:Program Manager;CLASS:Progman]")) Global $iHeight = 4 Global Const $hGUI = GUICreate("Screen Ruler Underline for free :-)", $aFullScreen[2], $iHeight, $aFullScreen[0], MouseGetPos(1), $WS_POPUP, BitOR($WS_EX_TOPMOST, $WS_EX_TRANSPARENT)) GUISetBkColor(0x000000) WinSetTrans($hGUI, "", 0xA0) GUISetState() HotKeySet("{ESC}", "_Exit") Do WinMove($hGUI, "", $aFullScreen[0], MouseGetPos(1)) Until Not Sleep(50) Func _Exit() GUIDelete() Exit EndFunc _____________ 1.1 #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> #include <WinAPI.au3> AutoItSetOption("GUIOnEventMode", 1) Global $hGUI, $hDC, $hPen, $obj_orig $hGUI = GUICreate("", @DesktopWidth, @DesktopHeight, 0, 0, $WS_POPUP) WinSetTrans($hGUI, "", 1) GUISetState() _line() Func _line() $hDC = _WinAPI_GetWindowDC(0) ; DC of entire screen (desktop) $hPen = _WinAPI_CreatePen($PS_SOLID, 2, 0x00ff) $obj_orig = _WinAPI_SelectObject($hDC, $hPen) GUISetOnEvent($GUI_EVENT_PRIMARYDOWN, "Draw", $hGUI) GUISetOnEvent(-3, "_Exit") Do Until Not Sleep(1000) EndFunc ;==>_line Func Draw() Local $aMC, $mxo, $myo $aMC = GUIGetCursorInfo($hGUI) Do GUISetCursor(0, 1, 0) $mxo = $aMC[0] $myo = $aMC[1] $aMC = GUIGetCursorInfo($hGUI) If $mxo <> $aMC[0] Or $myo <> $aMC[1] Then _WinAPI_DrawLine($hDC, $aMC[0], $aMC[1], $mxo, $myo) _WinAPI_RedrawWindow(_WinAPI_GetDesktopWindow(), 0, 0, $RDW_INVALIDATE) $mxo = $aMC[0] $myo = $aMC[1] EndIf Sleep(10) Until Not $aMC[2] EndFunc Func _Exit() _WinAPI_SelectObject($hDC, $obj_orig) _WinAPI_DeleteObject($hPen) _WinAPI_ReleaseDC(0, $hDC) Exit EndFunc
-
Solved the problem by using the example at _WinAPI_SetSystemCursor and created my own .cur file
-
I'm actually looking for a method to change the cursor color through a script. Also I'd like to keep the default cursor however change the colour of it from white to green.