Re: Table Highlighter (New AHK Script)
Awesome script, thx.
One more thing though, I was playing 4 sng's and when I closed one, when I busted one table stayed highlighted no matter what.
I couldn't figure out how you index the tables but I figure there must be a bug in there somewhere.
Here's some simple code that seems to work pretty well for a script I tried to write for pokerstars which takes the window id and transforms it into a dynamic unique number 1 - 20, so that if tables are added or closed it won't matter.
Init()
{
global
local myvar
Loop, 20
{
PaintArray%A_Index% = 0
}
return
}
CheckIndex(win)
{
global
r = 255
Loop, 20
{
if PaintArray%A_Index% = %win%
{
r = %A_Index%
break
}
}
; return index or 255 if not in index
return r
}
SetIndex(win)
{
global
r = 500
Loop, 20
{
if PaintArray%A_Index% = 0
{
PaintArray%A_Index% = %win%
r = %A_Index%
break
}
}
return r
}
RemoveIndex(indx)
{
global
PaintArray%indx% = 0
return
}
|