hment "c:\test_game","*.*"
set ws=createobject("Wscript.Shell")
ws.run "regsvr32 c:\test_game\dm.dll /s"
set ws=nothing
Delay 1500
Set dm = CreateObject("dm.dmsoft")
ver = dm.Ver()
dm.SetPath "f:/save"
Delay 100
dm.SetDict 0,"dm_soft.txt"
Delay 100
If len(ver) = 0 Then
MessageBox "创建对象失败,检查系统是否禁用了vbs脚本权限"
EndScript
End If
//寒风袭来制作
hwnd=dm.GetMousePointWindow()
dm_ret = dm.BindWindow(hwnd,"dx","dx","windows",0)
Delay 1500
dm.DownCpu 50
Delay 500
If dm_ret = 0 Then
MessageBox"绑定失败"
EndScript
End If
LockMouse
Delay 1000
//按下F12
dm.keypress 123
Delay 1000
dm.keypress 123
Delay 1000
//打开地图按键
dm.keypress 77
Delay 1000
//查找其他Npc
dm_ret=dm.FindStr(737,207,797,231,"其他Npc","ffd495-000000",1.0,x,y)
If x>=0 And y>=0 Then
dm.MoveTo x, y
Delay 500
dm.LeftDoubleClick
Delay 1000
Else
MessageBox "没找到其他Npc"
End If
//查找仓库保管员子仓
dm_ret=dm.FindStr(750,290,859,308,"管理员","ffd495-000000",1.0,x,y)
If x>=0 And y>=0 Then
dm.MoveTo x, y
Delay 500
dm.LeftDoubleClick
Delay 1000
Else
MessageBox "没找到仓库保管员"
End If
//关闭地图
dm.keypress 77
Delay 1000
//接帮派日常任务
i=0
While i=0
dm_ret=dm.FindStr(28,442,134,468,"日常","362000-000000",1.0,x,y)
If x>=0 And y>=0 Then
i=1
End If
Wend
dm.MoveTo x, y
Delay 500
dm.LeftDoubleClick
Delay 1000
//打开地图按M键
dm.keypress 77
Delay 1000
//找传送
dm_ret=dm.FindStr(735,166,795,189,"传送Npc","ffd495-000000",1.0,x,y)
If x>=0 And y>=0 Then
dm.MoveTo x, y
Delay 500
dm.LeftDoubleClick
Delay 1000
Else
MessageBox "地图传送没找到"
End If
//找天青