Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ;This section makes the flashing dofus window come to front, dont touch this without knowing what you are doing
- DetectHiddenWindows, On
- Script_Hwnd := WinExist("ahk_class AutoHotkey ahk_pid " DllCall("GetCurrentProcessId"))
- DetectHiddenWindows, Off
- DllCall("RegisterShellHookWindow", "uint", Script_Hwnd)
- OnMessage(DllCall("RegisterWindowMessage", "str", "SHELLHOOK"), "ShellEvent")
- ShellEvent(wParam, lParam) {
- if (wParam = 0x8006) HSHELL_FLASH
- {
- WinGet,descobre,ProcessName, ahk_id %lParam%
- if(descobre = "Dofus.exe")
- WinActivate, ahk_id %lParam%
- }
- }
- ;This section lets you switch windows with function keys, can be edited to match your character names
- #IfWinExist, Tocapilotes
- {
- F1::WinActivate Tocapilotes
- }
- #IfWinExist, Wondergirl
- {
- F2::WinActivate Wondergirl
- }
- #IfWinExist, Avia
- {
- F2::WinActivate Avia
- }
- #IfWinExist, Avi
- {
- F3::WinActivate Avi
- }
- #IfWinExist, Percose
- {
- F3::WinActivate Percose
- }
- #IfWinExist, Xenxoalt
- {
- F4::WinActivate Xenxoalt
- }
- #IfWinExist, Xenxotrof
- {
- F5::WinActivate Xenxotrof
- }
- #IfWinExist, Vella
- {
- F6::WinActivate Vella
- }
- #IfWinExist, Migdiada
- {
- F6::WinActivate Migdiada
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement