View Single Post
Rage2100
Old 03-20-2010, 04:55 PM #95 (permalink)  
Rage2100's Avatar
Full House

Join Date: Jan 2007
Location: UK
Posts: 719
Rage2100 is on a distinguished road
Firstly, I must thank Nakamura for discovering this little trick. By putting a ~ before a hotkey, the key retains it's native function. This means that by slightly changing the MoveTable code, you will be able to use the Spacebar to type notes, as well as to move the tables. In order to type notes, the mouse pointer must be in the following area of the table. If you want to make the area bigger or smaller, this can easily be altered. I'll ask Nakamura to find the co-ordinates for Full Tilt tables, or you can find them yourselves.




Here is the code you need to change. Please use the version that matches your configuration.

Configuration 1 (main stack in upper left position)

Code:
~space::
CoordMode, Mouse, Relative
MouseGetPos, MX, MY, tableID
IfWinExist, ahk_id %tableID%
WinGetPos, X, Y, W, H, %ahk_id%
WinGetClass, class
If class=%Class_Name%
{
BLX:=W*0.0059
BLY:=H*0.7677
BRX:=W*0.3327
BRY:=H*0.9903

If (MX > BLX) AND (MX < BRX) AND (MY > BLY) AND (MY < BRY)
   {
   } else

If (X < (X_home + T)) AND (Y < (Y_home + T))
{
 Send, {Backspace}
   If (S1 <= S2) AND (S1 <= S3)
   {
    WinMove,,, Slot1_X, Slot1_Y
    S1+=1
      } else
         If (S2 < S1) AND (S2 <= S3)
         {
          WinMove,,, Slot2_X, Slot2_Y
          S2+=1
         } else
            If (S3 < S1) AND (S3 < S2)
            {
             WinMove,,, Slot3_X, Slot3_Y
             S3+=1
            }

} else
   If (X > (Slot1_X - T)) AND (Y < (Slot1_Y + T))
   {
    Send, {Backspace}
      If S1 > 0
      {
       WinMove,,, X_home, Y_home
       S1-=1
      } else
         WinMove,,, X_home, Y_home

} else
   If (X > (Slot2_X - T)) AND (Y > (Slot2_Y - T))
   {
    Send, {Backspace}
      If S2 > 0
      {
       WinMove,,, X_home, Y_home
       S2-=1
      } else
         WinMove,,, X_home, Y_home

} else
   If (X < (Slot3_X + T)) AND (Y > (Slot3_Y - T))
   {
    Send, {Backspace}
      If S3 > 0
      {
       WinMove,,, X_home, Y_home
       S3-=1
      } else
         WinMove,,, X_home, Y_home
}
}
return
Configuration 2 (main stack in lower right position)

Code:
~space::
CoordMode, Mouse, Relative
MouseGetPos, MX, MY, tableID
IfWinExist, ahk_id %tableID%
WinGetPos, X, Y, W, H, %ahk_id%
WinGetClass, class
If class=%Class_Name%
{
BLX:=W*0.0059
BLY:=H*0.7677
BRX:=W*0.3327
BRY:=H*0.9903

If (MX > BLX) AND (MX < BRX) AND (MY > BLY) AND (MY < BRY)
   {
   } else

If (X > (X_home - T)) AND (Y > (Y_home - T))
{
 Send, {Backspace}
   If (S1 <= S2) AND (S1 <= S3)
   {
    WinMove,,, Slot1_X, Slot1_Y
    S1+=1
      } else
         If (S2 < S1) AND (S2 <= S3)
         {
          WinMove,,, Slot2_X, Slot2_Y
          S2+=1
         } else
            If (S3 < S1) AND (S3 < S2)
            {
             WinMove,,, Slot3_X, Slot3_Y
             S3+=1
            }

} else
   If (X > (Slot1_X - T)) AND (Y < (Slot1_Y + T))
   {
    Send, {Backspace}
      If S1 > 0
      {
       WinMove,,, X_home, Y_home
       S1-=1
      } else
         WinMove,,, X_home, Y_home

} else
   If (X < (Slot2_X + T)) AND (Y < (Slot2_Y + T))
   {
    Send, {Backspace}
      If S2 > 0
      {
       WinMove,,, X_home, Y_home
       S2-=1
      } else
         WinMove,,, X_home, Y_home

} else
   If (X < (Slot3_X + T)) AND (Y > (Slot3_Y - T))
   {
    Send, {Backspace}
      If S3 > 0
      {
       WinMove,,, X_home, Y_home
       S3-=1
      } else
         WinMove,,, X_home, Y_home
}
}
return
The BLX, BLY, BRX and BRY control the size of the red area shown in the picture. Basically, they are just percentage values, with BLX (box left X) being the X co-ordinate of the top left corner of the box, which is 0.59% the width of the overall table.

If you take notes in HEM or PT3, you should just be able to add the ~ before the hotkey, although I've not had chance to test this yet.
Reply With Quote