Jump to content

alan666

Members
  • Posts

    3
  • Joined

  • Last visited

alan666's Achievements

Seeker

Seeker (1/7)

0

Reputation

  1. a really dont know what im doing. I want the program to check the colour in holdem inspector then hit the relevent button in the poker window. got the code from someone else. Think it just needs a few fixes. But Im completely stuck
  2. When I start the script .. nothing happens. when i click the icon it flashes an X and says script paused. Thanks
  3. I have poker inspector and party poker and want to link the 2 together but I am having problems with the script. Here it is thanks in advance..... ; ---------------------------------------------------------------------------- ; ; AutoIt Version: 3.1.0 ; Author: A.N.Other <myemail@nowhere.com> ; ; Script Function: ; Template AutoIt script. ; ; ---------------------------------------------------------------------------- ; Script Start - Add your code below here ; Pre-initialization : Set Name of Table Global $tablename = "play money 4071223 holdem- 5/10." ; Initialize Buttons ; These are the button names you might have to change these for different poker clients $FoldButton = "AfxWnd42u22" $CheckButton = "AfxWnd42u25" $CallButton = "AfxWnd42u25" $BetButton = "AfxWnd42u27" $RaiseButton = "AfxWnd42u27" ; Set Coordinate mode to relative to window AutoItSetOption ( "PixelCoordMode", 0 ) ; Wait for the window of table to become active Winwait($tablename) ; Main Loop While WinExists($tablename) Sleep(300); $FoldVisible = ControlCommand($tablename, "", $FoldButton, "IsVisible", ""); $RaiseVisible = ControlCommand($tablename, "", $RaiseButton, "IsVisible", ""); if $FoldVisible = 1 then Sleep(Random(1500, 2500)) $action = GetAction(); if $action = 1 then ; Fold/Check ; if we can check for free, then do that instead of folding if StringInStr(ControlGetText($tablename, "", $CheckButton), "Check") = 1 then ControlClick($tablename, "", $CheckButton); else ControlClick($tablename, "", $FoldButton); endif elseif $action = 2 then ; Check/Call ;Sleep(Random(0, 2000)); ControlClick($tablename, "", $CallButton); elseif $action = 3 then ; Call/Bet ; if we can call then call otherwise bet if StringInStr(ControlGetText($tablename, "", $CallButton), "Call") = 1 then ControlClick($tablename, "", $CallButton); else ControlClick($tablename, "", $BetButton); endif elseif $action = 4 then ; Bet/Raise ;Sleep(Random(0, 2000)); ControlClick($tablename, "", $RaiseButton); endif WEnd ; Poker Inspector Actions Func GetAction() WinActivate ("Connected to """ & $tablename); ; red - fold $color = PixelGetColor (338, 65); if $color = 255 then WinActivate($tablename); return 1; endif ;yellow $color = PixelGetColor (337, 74); if $color = 65535 then WinActivate($tablename); return 2; endif ; blue $color = PixelGetColor (337, 84); if $color = 16776960 then ; sometimes bet or just call 50% of the time WinActivate($tablename); return 3; endif ; green $color = PixelGetColor (337, 97); if $color = 65280 then ; If we've got the nuts or close to then sometimes just check 20% of the time ; otherwise raise or reraise WinActivate($tablename); return 4; endif WinActivate($tablename); return 1; EndFunc ; Checks how many empty seats there are Func OccupiedSeats() Local $Count = 0 Local $SeatOpenColor = 3246765 ;Seat 1 If (PixelGetColor(517, 96) == $SeatOpenColor) Then $Count = $Count + 1; EndIf ;Seat 2 If (PixelGetColor(665, 133) == $SeatOpenColor) Then $Count = $Count + 1; EndIf ;Seat 3 If (PixelGetColor(735, 251) == $SeatOpenColor) Then $Count = $Count + 1; EndIf ; Seat 4 If (PixelGetColor(660, 378) == $SeatOpenColor) Then $Count = $Count + 1; EndIf ; Seat 5 If (PixelGetColor(493, 413) == $SeatOpenColor) Then $Count = $Count + 1; EndIf ; Seat 6 If (PixelGetColor(262, 413) == $SeatOpenColor) Then $Count = $Count + 1; EndIf ; Seat 7 If (PixelGetColor(108, 378) == $SeatOpenColor) Then $Count = $Count + 1; EndIf ; Seat 8 If (PixelGetColor(53, 247) == $SeatOpenColor) Then $Count = $Count + 1; EndIf ; Seat 9 If (PixelGetColor(126, 133) == $SeatOpenColor) Then $Count = $Count + 1; EndIf ; Seat 10 If (PixelGetColor(264, 96) == $SeatOpenColor) Then $Count = $Count + 1; EndIf return $Count; EndFunc
×
×
  • Create New...