以下是写出的脚本 运行也没有出错 WOW 2#宏的命令也写好的,单独运行也没有出错,但是贴上脚本 怎么运行呢 WOW 1# 按键, 1 按了 WOW 2# 还是没反应啊!~
#Persistent
WinGet, wowid, List, 魔兽世界
~1::
KeyWait 1
IfWinActive, 魔兽世界
{
ControlSend,, 1, ahk_id %wowid1%
ControlSend,, 1, ahk_id %wowid2%
Return
}
WinGet, wowid, List, 魔兽世界
~2::
KeyWait 2
IfWinActive, 魔兽世界
{
ControlSend,, 2, ahk_id %wowid1%
ControlSend,, 2, ahk_id %wowid2%
Return
}
WinGet, wowid, List, 魔兽世界
~3::
KeyWait 3
IfWinActive, 魔兽世界
{
ControlSend,, 3, ahk_id %wowid1%
ControlSend,, 3, ahk_id %wowid2%
Return
}
WinGet, wowid, List, 魔兽世界
~e::
KeyWait e
IfWinActive, 魔兽世界
{
ControlSend,, e, ahk_id %wowid1%
ControlSend,, e, ahk_id %wowid2%
Return
}
WinGet, wowid, List, 魔兽世界
~r::
KeyWait r
IfWinActive, 魔兽世界
{
ControlSend,, r, ahk_id %wowid1%
ControlSend,, r, ahk_id %wowid2%
Return
}
WinGet, wowid, List, 魔兽世界
~t::
KeyWait t
IfWinActive, 魔兽世界
{
ControlSend,, t, ahk_id %wowid1%
ControlSend,, t, ahk_id %wowid2%
Return
}
WinGet, wowid, List, 魔兽世界
~z::
KeyWait z
IfWinActive, 魔兽世界
{
ControlSend,, z, ahk_id %wowid1%
ControlSend,, z, ahk_id %wowid2%
Return
}
WinGet, wowid, List, 魔兽世界
~v::
KeyWait v
IfWinActive, 魔兽世界
{
ControlSend,, v, ahk_id %wowid1%
ControlSend,, v, ahk_id %wowid2%
Return
}
WinGet, wowid, List, 魔兽世界
~q::
KeyWait q
IfWinActive, 魔兽世界
{
ControlSend,, q, ahk_id %wowid1%
ControlSend,, q, ahk_id %wowid2%
Return
}
WinGet, wowid, List, 魔兽世界
~4::
KeyWait 4
IfWinActive, 魔兽世界
{
ControlSend,, 4, ahk_id %wowid1%
ControlSend,, 4, ahk_id %wowid2%
Return
}
WinGet, wowid, List, 魔兽世界
~5::
KeyWait 5
IfWinActive, 魔兽世界
{
ControlSend,, 5, ahk_id %wowid1%
ControlSend,, 5, ahk_id %wowid2%
Return
}
我自己已经做出来了 有需要的朋友可以去我的空间日志看下
http://user.qzone.qq.com/77309568/blog/1286859944