dim a,s,k,t1,t2,t3,color,x,y
Rem 挂机模式
VBSCall a=InputBox("请输入挂机抢怪模式(数字) 0为抢怪 1为不抢")
s=Len(a)
If s=1
If a="0"
a=347
ElseIf a="1"
a=512
Else
MessageBox "错误:请重新输入 0或1"
Goto 挂机模式
EndIf
Else
MessageBox "错误:小样 耍我啊?"
Goto 挂机模式
EndIf
t1=now:t2=now:t3=now
k=49
//***************〖开始挂机〗*****************
Rem 找怪
Gosub 辅助技能
KeyPressH 9,1
Delay 100
Rem 判断怪血条
VBSCall color=GetPixelColor(a,77)
If color="383BEE" or color="000293"
Delay 100
//使用攻击技能 技能放在1,2,3
KeyPressH k,1
k=k+1
If k>51
k=49
EndIf
Rem 普通攻击
KeyPressH 192,5
Gosub 自动用药
Gosub 判断障碍物
Rem 判断怪死亡
IfColor 347,75,0004D3,1
Delay 2000
KeyPressH 192,1
Rem 判断捡物框
IfColor 675,212,6fe1f9,0
KeyPressH 192,1
Goto 判断捡物框
EndIf
Goto 找怪
EndIf
Goto 普通攻击
EndIf
Goto 找怪
//**************〖子程序〗**************
Sub 辅助技能
//120为120秒 可自己修改时间 按键可自己修改
If DateDiff("s",t1,now)>=120
//辅助技能1 自己修改
t1=now
EndIf
If DateDiff("s",t2,now)>=120
//辅助技能2 自己修改
t2=now
EndIf
If DateDiff("s",t3,now)>=120
//辅助技能3 自己修改
t3=now
EndIf
Return 辅助技能
Sub 自动用药
Rem HP
IfColor 154,73,2d0995,1
IfColor 154,76,3710c1,1
//加HP命令 自己修改
EndIf
EndIf
Rem MP
IfColor 152,90,96420c,1
IfColor 152,92,b44d0b,1
//加MP命令 自己修改
EndIf
EndIf
Rem SP
IfColor 143,104,a8ead7,1
IfColor 143,106,93dcc8,1
//加SP命令 自己修改
EndIf
EndIf
Return 自动用药
Sub 判断障碍物
Delay 100
VBSCall FindPic(330,155,440,310,"Attachment:\1.bmp",0.9,x,y)
If x>=330 and y>=155
Goto 找怪
EndIf
Return 判断障碍物