For 32
//从找图修改为只循环购买32次(一背包数量)
//调用易语言插件进行判断背包剩余金额
//Plugin.e.test1 窗口句柄,报警金额
//Delay 500
//利用公告图片判断。如果找到则说明不能继续购买,反之则继续买
//判断购买腰带种类
If 分解装备 = 0 Then
MoveTo X+10,Y+10
End If
If 分解装备 = 1 Then
MoveTo X+50,Y+10
End If
Delay 100
LeftClick 2
//FindPic 0, 0, 600, 800, "Attachment:\公告.bmp",0.9, intX, intY
Delay 100
Next
Call 点击确定()
//调用点击确定来关掉公告框,然后关闭购买的物品框
KeyPress "Esc", 1
//购买腰带步骤结束。如果需要买别的可以自己改坐标或者图片
End Sub
Sub 到塞莉亚房间
//250,180
//到塞莉亚房间思路:首先判断地图是否打开。如果没有打开则打开地图,反之直接根据坐标移动
Rem B
FindPic 0, 0, 800, 600, "Attachment:\地图判断.bmp", 0.9, intX, intY
While intX = - 1 and intY = - 1
MoveTo 784, 16
LeftClick 1
Delay 500
FindPic 0, 0, 800, 600, "Attachment:\地图判断.bmp", 0.9, intX, intY
Wend
//打开地图完成。接下来右键点击坐标移动到塞莉亚房间前(DNF不能用寻路直接到塞莉亚房间)
MoveTo 304, 283
RightClick 1
MoveTo 800, 600
//接下来不停的找点判断是否到了塞莉亚房间前
FindColor 0, 0, 640, 480, "FDCA09", X2, Y2
While X2 <> 303 and Y2 <> 279
//X3 = X2
// Y3 = Y2
Delay 2000
X3 = X2
Y3 = Y2
If X3 = - 1 and Y3 = - 1 Then
Delay 100
KeyPress "Esc", 2
Delay 100
Call 点击确定()
Delay 100
Goto B
End If
Delay 500
FindColor 0, 0, 800, 600, "FDCA09", X2, Y2
If X3 = X2 and Y3 = Y2 Then
停止次数 = 停止次数 + 1
Else
停止次数 = 0
X3 = X2
Y3 = Y2
End If
If 停止次数 >= 4 Then
Delay 100
KeyPress "Esc", 2
Delay 100
Call 点击确定()
Delay 100
Goto B
End If
If Y2 = 181 Then
Y2 = 180
End If
MoveTo 304,283
RightClick 1
MoveTo 200,0
Wend
//到这里则说明角色移动到了塞莉亚房前了。那么只要模拟↑就能进去了
FindPic 0, 0, 800, 600, "Attachment:\地图判断.bmp", 0.9, intX, intY
While intX > - 1 and intY > - 1
MoveTo 786, 14
LeftClick 5
Delay 200
FindPic 0, 0, 800, 600, "Attachment:\地图判断.bmp", 0.9, intX, intY
Wend
//继续判断是否成功进入塞莉亚房间,如果成功则完成子程序,失败则重新进入房间
Call 判断角色()
If 位置 = 0 Then
KeyDown "Down", 1
Delay 3000
KeyPress "Down", 1
Delay 500
Goto B
End If
End Sub
Sub 架设分解机
//架设前让角色移动位置...
KeyPress "Up", 20
Rem C