Advertisement
Siwy_Krzysiek

Deck tracker

Jun 22nd, 2017
94
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #NoEnv  ; Recommended for performance and compatibility with future AutoHotkey releases.
  2. ; #Warn  ; Enable warnings to assist with detecting common errors.
  3. SendMode Input  ; Recommended for new scripts due to its superior speed and reliability.
  4. SetWorkingDir %A_ScriptDir%  ; Ensures a consistent starting directory.
  5.  
  6. #SingleInstance force
  7.  
  8. trackerDziala := false
  9.  
  10. Loop
  11. {  
  12.     IfWinExist, Hearthstone ahk_class UnityWndClass
  13.     {
  14.         if(!trackerDziala)
  15.         {
  16.             IfWinNotExist, Hearthstone Deck Tracker
  17.             {
  18.                 trackerDziala := true
  19.                 Run, HearthstoneDeckTracker.exe, C:\Users\Krzysiek\AppData\Local\HearthstoneDeckTracker
  20.                 Sleep, 5000
  21.             }
  22.         }
  23.     }
  24.    
  25.     IfWinNotExist, Hearthstone ahk_class UnityWndClass
  26.     {
  27.         if(trackerDziala)
  28.         {
  29.             IfWinExist, Hearthstone Deck Tracker
  30.             {
  31.                 WinClose, Hearthstone Deck Tracker
  32.                 trackerDziala := false
  33.             }
  34.         }
  35.     }
  36.    
  37.     Sleep 100
  38. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement