Re: A pretty short AHK script I made - Fastest NL script i\'ve tried
[ QUOTE ]
Any thought on how to get this to work for Stars or Absolute?
I attempted to convert it, but WindowSpy doesn't show any controls.
[/ QUOTE ]
This should work for Stars (both play money and real money); I haven't tested every limit/tourney type though.
SetTitleMatchMode 2
return
#IfWinActive Logged In as
WheelUp::
WinGet, id,, A
SetText(id, "up")
return
WheelDown::
WinGet, id,, A
SetText(id, "down")
return
SetText(win, dir)
{
WinGetTitle, title, ahk_id%win%
If (InStr(title, "No Limit") <> 0 AND InStr(title, "Tournament") = 0) ;___if "NL" is in the title but "Tournament" isn't...
StringMid, bb, title, InStr(title, "/") + 1, InStr(title, a_space,"", InStr(title, "/")) - InStr(title, "/") - 1 ;___retrieve the big blind
else if (InStr(title, "No Limit") <> 0 AND InStr(title, "Tournament") <> 0) ;___else this is a tourney
{
StringMid, bb, title, InStr(title, "/", "", InStr(title, "Blinds")) + 1
, InStr(title, a_space, "", InStr(title, "Blinds") + 8) - InStr(title, "/", "", InStr(title, "Blinds")) - 1 ;___so we retrieve the big blind instead
}
StringReplace, bb, bb, $,,1
ControlGetText, t, Edit6, %title% ;___retrieve the text from the edir next to the slider
If dir = up
t := t + bb
else
t := t - bb
If t >= 0
ControlSetText, Edit6, %t%, %title%
}
|