本帖最後由 kelvin_mo 於 2009-9-21 00:35 編輯
戰慄殺手可放輔助技、不搶怪、遇到阻擋、點到NPC、會休息、會補血的腳本
#[HOTKEY][EXT]F10
function main
SetInputMode(3) //驅動模式,很多遊戲會阻擋SP的部份功能,可以套用此函數
while true //循環開始
State() //子函數狀態
wend //返回while開始循環
end function
function State//休息攻擊+喝水
//取窗口原點坐標
GetActiveWindowXY(WinX0, WinY0)
print("休息")
if not CheckColor(WinX0+347, WinY0+909, Color(218, 41, 79), 10) then//人物血量剩餘多少以下休息
Wait(100)
KeyPress("F")
Wait(300)
KeyDown("x")
Wait(5000)
KeyUp("x")
do //循環
Wait(500)
loop until CheckColor(WinX0+363, WinY0+910, Color(180, 33, 66), 10)//直到血量到達
end if
GetActiveWindowXY(WinX0, WinY0)
if not CheckColor(WinX0+720, WinY0+31, Color(103, 19, 35), 10) then//怪物血量沒滿
do
KeyDown("Tab")
Wait(100)
KeyUp("Tab")
Wait(500)
loop until CheckColor(WinX0+720, WinY0+31, Color(103, 19, 35), 10)//怪物滿血的位置
end if
GetActiveWindowXY(WinX0, WinY0)
if not CheckColor(WinX0+561, WinY0+10, Color(201, 196, 111), 10) then//指定目標的種類
do
Print("Npc")
KeyDown("Tab")
Wait(100)
KeyUp("Tab")
Wait(500)
loop until CheckColor(WinX0+720, WinY0+31, Color(103, 19, 35), 10)//怪物滿血的位置
else //找到的話…
do//執行攻擊
Print("攻擊")
for ForCount = 1 to 1
KeyDown("1")
Wait(8000)
KeyUp("1")
KeyDown("2")
Wait(3000)
KeyUp("2")
Wait(1000)
GetActiveWindowXY(WinX0, WinY0)
if not CheckColor(WinX0+301, WinY0+911, Color(219, 42, 83), 10) then
Print("補血")
KeyPress("4")
wait(300)
end if
GetActiveWindowXY(WinX0, WinY0)
if CheckColor(WinX0+738, WinY0+138, Color(250, 210, 0), 10) then
Print("無法攻擊")
KeyDown("2")
Wait(3000)
KeyUp("2")
Wait(3000)
KeyDown("Tab")
Wait(100)
KeyUp("Tab")
Wait(1000)
end if
next
loop while CheckColor(WinX0+579, WinY0+29, Color(108, 49, 54), 10)//怪物血量到達0如果還有血會跳回去
Print("死亡")
KeyDown("2")
Wait(1000)
KeyUp("2")
Wait(100)
KeyPress("ESC")
Wait(500)
KeyPress("F")
Wait(1000)
end if
GetActiveWindowXY(WinX0, WinY0)
if not CheckColor(WinX0+148, WinY0+13, Color(162, 55, 31), 10) then
Print("輔助")
KeyDown("F1")
Wait(1000)
KeyUp("F1")
KeyDown("5")
Wait(1500)
KeyUp("5")
end if
end function
畫面請用1280*1024
瞄準射擊放1
急速射擊放2
補品放4
熱血沸騰放5
其他建議:如果要掛請換命中裝備會比較有效率
如果回文數可觀在發其他職業 |