Now watches for process instead of window
Deciding whether or not a tool is already up by a window existing fails if the tool is started, but hasn’t created a window yet. This is not an issue if watching for the _process_ to pop up. Ideally this would also close processes instead of windows when the watched game goes down, but killing a process from AHK sadly is ungraceful, unlike closing a window.
This commit is contained in:
parent
0e9813fad2
commit
59d63e42b0
2 changed files with 12 additions and 1 deletions
10
CHANGELOG.md
10
CHANGELOG.md
|
@ -1,3 +1,13 @@
|
|||
# devel
|
||||
|
||||
## Changed
|
||||
|
||||
* Now watches for a _process_ instead of a _window_ for checking if a tool is
|
||||
already up. This means stuff isn’t started multiple times if the window takes
|
||||
a while to pop up.
|
||||
|
||||
-----
|
||||
|
||||
# v0.2.0 (2021-01-20)
|
||||
|
||||
This release adds proper support for devices beyond just Joysticks, e.g.
|
||||
|
|
|
@ -125,7 +125,8 @@ watchTarget() {
|
|||
; start tools
|
||||
for ip, path in config["tools"]["paths"] {
|
||||
SplitPath, path, file
|
||||
if (!WinExist("ahk_exe " file)) {
|
||||
Process, Exist, %file%
|
||||
if (!ErrorLevel) {
|
||||
Run, % path
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue