Sub 读取输入金币数
ss1 = dm.Ocr(152,282,316,319, "fff000-000000", 1.0)
ss2 = dm.Ocr(152,282,316,319, "ff8c00-000000", 1.0)
ss3 = dm.Ocr(152,282,316,319, "ff5000-000000", 1.0)
tempzj = ss1 & ss2 & ss3
End Sub
Sub 附近检测
fj = dm.Ocr(38, 389, 125, 426, "eeddaa-000000", 1.0)
If fj = 99999 Then
ifj=0
End If
End Sub
Sub 关机
gbjsj = lib.窗口.弹出对话框("游戏掉线是否关闭计算机?",60,"",4)
If gbjsj = 6 Then //值为6是选择是
sDate = Plugin.Sys.GetDateTime()
Call Plugin.File.WriteFileEx("c:\log.txt", sdate & "游戏掉线 关闭计算机")
sms = Lib.网络.发送邮件("i0_0i_@139.com", "521~jian", sjyx,yjnr, "【 -_-。sorry!悲剧了....】", 0)
If sms = true Then
返回值 = lib.窗口.弹出对话框("发送邮件成功",10,"",1)
Call Plugin.File.WriteFileEx("c:\log.txt", sdate & "邮件发送成功")
End If
Call Plugin.Sys.ExitOS(1) //关机
//MessageBox "guanji"
ElseIf gbjsj = 7 Then
sDate = Plugin.Sys.GetDateTime()
Call Plugin.File.WriteFileEx("c:\log.txt", sdate&"游戏掉线 推出脚本")
//MessageBox "推出脚本"
ExitScript
End If
//MessageBox "guanji"
sDate = Plugin.Sys.GetDateTime()
Call Plugin.File.WriteFileEx("c:\log.txt", sdate & "游戏掉线 关闭计算机")
sms = Lib.网络.发送邮件(fjyx, fjyxpwd, sjyx, yjnr, "【 -_-。sorry!悲剧了....】", 0)
If sms = true Then
返回值 = lib.窗口.弹出对话框("发送邮件成功",10,"",1)
Call Plugin.File.WriteFileEx("c:\log.txt", sdate & "邮件发送成功")
End If
Call Plugin.Sys.ExitOS(1) //关机
End Sub
Sub 移动
For 22
dm.KeyPress 37 //向左
Next
For 22
dm.KeyPress 39 //向右
Next
For 30
dm.KeyPress 40 //向下
Next
End Sub
Sub 大漠初始化
PutAttachment "c:\test_game","*.*"
set ws=createobject("Wscript.Shell")
ws.run "regsvr32 c:\test_game\dm.dll /s"
set ws=nothing
Delay 1000
Set dm = CreateObject("dm.dmsoft") //大漠插件对象的插件
ver = dm.Ver()
set dmsz = createobject("dm.dmsoft") //创建数字识别的对象
base_path = dm.GetBasePath()
dm_ret = dm.SetPath(base_path)
dm_ret = dm.SetDict(0,"数字dm.txt")
If len(ver) = 0 Then
MessageBox "创建对象失败,检查系统是否禁用了vbs脚本权限"
EndScript
End If
End Sub
Sub 日志
shuliang=shuliang&"总计:"&zj
m1 = Minute(time)
m2 = hour(time)
m12=m2&":"&m1
Call Plugin.File.WriteFileEx("c:\log.txt", m12)