Update wow watchdog
This commit is contained in:
parent
25af70f24f
commit
d5a334ec42
@ -1,7 +1,15 @@
|
||||
$WATCHDOG=0
|
||||
|
||||
for (;;) {
|
||||
$NRESP = Get-Process | Where-Object {$_.mainWindowTitle} | Where -Property MainWindowTitle -eq "World of Warcraft" | Where -Property Responding -eq $false
|
||||
|
||||
if ($NRESP) {
|
||||
$WATCHDOG += 1
|
||||
} else {
|
||||
$WATCHDOG = 0
|
||||
}
|
||||
|
||||
if ($WATCHDOG -ge 5) {
|
||||
Stop-Process -InputObject $NRESP
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user