PortValhalla/scripts/Windows/Software/tobii-gamehub/GameHub.ahk

26 lines
589 B
AutoHotkey

InstallGameHub()
{
SetDefaultMouseSpeed(100)
SetTitleMatchMode("RegEx")
windowTitle := "^Tobii Game Hub$"
Run("setup.exe")
WinWait(windowTitle, unset, 60)
WinActivate(windowTitle)
Sleep(2 * 1000)
MouseClick("Left", 485, 365)
MouseClick("Left", 600, 455)
MouseClick("Left", 533, 623)
MouseClick("Left", 936, 662)
Sleep(4 * 1000)
WinActivate(windowTitle)
MouseClick("Left", 1150, 60)
MouseClick("Left", 518, 203)
Sleep(10 * 1000)
WinActivate(windowTitle)
pid := WinGetPID()
Run("pwsh -c Stop-Process -Force " . pid)
}
SetWorkingDir(A_InitialWorkingDir)
InstallGameHub()