当前位置:文档之家› 来自按键精灵的DNF刷第一图源码

来自按键精灵的DNF刷第一图源码

来自按键精灵的DNF刷第一图源码被虐疯了才憋出一个可以解恨的DNF刷图源码,源码内包含了换角色、改键、区域移动、地图选择、出售、封装识别。

18个地图的一图(其他地图可以自己修改下就可以刷全部图的一图)主要是给新手学习的,老鸟别喷。

附件在下面,做了很久了,随着游戏更新现在不一定能正常使用可以自己修改下:PutAttachment ".\plugin" ,"*.dll"UserVar dtxz=DropList{"洛兰(1)":"0"|"洛兰深处(2)":"1"|"幽暗密林(3)":"2"|"雷鸣废墟(5)":"3"|"冰霜幽暗密林(8)":"4"|"烈焰格拉卡(12)":"5"|"龙人之塔(16)":"6"|"人偶玄关(18)":"7"|"石巨人塔(20)":"8"|"黑暗玄廊(22)":"9"|"城主宫殿(25)":"10"|"神殿外围(27)":"11"|"树精丛林(28)":"12"|"炼狱(29)":"13"|"极昼(30)":"14"|"第一脊椎(32)":"15"|"第二脊椎(34)":"16"|"天帷禁地(36)":"17"|"()":"5"|"()":"5"|"()":"5"|"()":"5"|"()":"5"|"()":"5"|"()":"5"|"()":"5"}=0 "地图选择"UserVar bjfs=DropList{"机箱":"0"|"音响":"1"}=0 "报警方式"UserVar jsgh=DropList{"更换":"0"|"不换":"1"}=0 "角色更换"UserVar jssl=1 "角色数量"UserVar jhks=1 "几号开始"UserVar jtj1=0 "进图按键"UserVar jtj2=0 "进图按键"UserVar jtj3=0 "进图按键"UserVar ctj1=0 "出图按键"UserVar ctj2=0 "出图按键"UserVar jqaj=0 "捡取按键"UserVar csaj=0 "出售按键"Hwnd = Plugin.Window.Find(0, "地下城与勇士")Call Plugin.Window.Move(Hwnd, 0, 0)Delay 1000Rem 主程序Call 选择角色()Call 疲劳改键()Call 移动区域()Call 地图选择()Goto 主程序Sub 选择角色()If jsgh=0 ThenIfColor 210,440,"6B949C",0 Thenjsx=117jsy=137If jhks<5 ThenFor jhks-1jsx=jsx+130NextElseFor jhks-5jsx=jsx+130Nextjsy=jsy+185End Ifjhks=jhks+1MoveTo jsx, jsyLeftClick 1Delay 1000MoveTo 322, 448LeftClick 1ElseIf jhks>jssl ThenCall 报警提醒()End IfFor 3IfColor 316,271,"484849",0 ThenElseMoveTo 39, 434LeftClick 1Delay 300KeyPress "Esc", 1Delay 1000End IfNextMoveTo 316, 344LeftClick 3For 30IfColor 210,440,"6B949C",0 ThenGoto 主程序ElseDelay 1000End IfNextCall 报警提醒()End IfEnd IfEnd SubSub 疲劳改键()For 30IfColor 40,400,"608A9D",0 ThenIfColor 278,437,"F78C00",0 ThenGoto 疲劳改键ElseMoveTo 39, 434LeftClick 1Delay 300KeyPress "Esc", 1Delay 1000End IfNextIf jsgh=1 ThenCall 报警提醒()End IfGoto 主程序ElseDelay 1000End IfNextCall 报警提醒()Rem 疲劳改键For 3IfColor 316,271,"484849",0 ThenElseKeyPress "Esc", 1Delay 1000End IfNextMoveTo 315, 317LeftClick 3Delay 1000MoveTo 407, 163LeftClick 1Delay 300KeyPress "W", 1Delay 300KeyPress "A", 1Delay 300KeyPress "S", 1Delay 300KeyPress "D", 1Delay 300MoveTo 372, 401LeftClick 1LeftClick 1Delay 1000For 3IfColor 566,38,"8DEDFF",0 ThenElseMoveTo 344, 188LeftClick 1Delay 1000MoveTo 404, 240LeftClick 1Delay 1000End IfNextMoveTo 163, 401LeftClick 1Delay 300Call 出售物品()End SubSub 移动区域()KeyDown "S", 1Delay 8000KeyUp "S", 1Delay 300If dtxz<2 ThenMoveTo 400, 360RightClick 1Delay 1000KeyDown "D", 1zyj=1End IfIf dtxz>1 And dtxz<6 ThenKeyDown "S", 1Delay 300KeyDown "A", 1Delay 3500KeyUp "S", 1zyj=0End IfIf dtxz>5 And dtxz<11 ThenKeyDown "D", 1zyj=1End IfIf dtxz>10 And dtxz<18 ThenMoveTo 20, 90RightClick 1Delay 5000MoveTo 280, 380RightClick 1Delay 1000KeyDown "D", 1zyj=1End IfFor 50IfColor 573,428,"8DC5DD",0 ThenGoto 移动区域ElseDelay 1000End IfNextCall 报警提醒()Rem 移动区域If zyj=0 ThenKeyUp "A", 1ElseKeyUp "D", 1End IfDelay 300End SubSub 地图选择()If dtxz=0 Thendtx=147dty=389End IfIf dtxz=1 Thendtx=309dty=384End IfIf dtxz=2 Thendtx=147dty=389End IfIf dtxz=3 Thendtx=472dty=352End IfIf dtxz=4 Thendtx=123End IfIf dtxz=5 Thendtx=340dty=188 End IfIf dtxz=6 Thendtx=130dty=376 End IfIf dtxz=7 Thendtx=295dty=391 End IfIf dtxz=8 Thendtx=441dty=331 End IfIf dtxz=9 Thendtx=504dty=256 End IfIf dtxz=10 Thendtx=366dty=181 End IfIf dtxz=11 Thendtx=192dty=227 End IfIf dtxz=12 Thendtx=340dty=188 End IfIf dtxz=13 Thendtx=494dty=192 End IfIf dtxz=14 Thendtx=518dty=269 End IfIf dtxz=15 Thendtx=472End IfIf dtxz=16 Thendtx=309dty=384End IfIf dtxz=17 Thendtx=147dty=389End Ifcswp=0Rem 地图选择If zyj=0 ThenKeyDown "D", 1Delay 500KeyUp "D", 1KeyDown "A", 1ElseKeyDown "A", 1Delay 500KeyUp "A", 1KeyDown "D", 1End IfFor 30IfColor 573,428,"8DC5DD",0 ThenIf zyj=0 ThenKeyUp "A", 1ElseKeyUp "D", 1End IfDelay 300For 10IfColor 573,428,"8DC5DD",0 ThenKeyPress "D", 3Delay 300MoveTo dtx, dtyLeftClick 1Delay 1000ElseCall 地图内部()Goto 地图选择End IfNextDelay 30000Goto 主程序ElseDelay 1000End IfNextCall 报警提醒()End SubSub 地图内部()For 30IfColor 40,400,"608A9D",0 ThenKeyPress "Esc", 3Delay 300KeyPress jtj1, 1Delay 300KeyPress jtj2, 1Delay 300KeyPress jtj3, 1Delay 300For 50IfColor 582,49,"263C44",0 ThenIfColor 582,88,"102129",0 ThenIfColor 562,68,"102931",0 ThenIfColor 602,68,"102131",0 ThenFor 5KeyPress "X", 1Delay 300NextElseGoto 地图内部End IfElseGoto 地图内部End IfElseGoto 地图内部End IfElseGoto 地图内部End IfNextGoto 地图内部ElseDelay 1000End IfNextCall 报警提醒()Rem 地图内部KeyPress ctj1, 1Delay 300KeyPress ctj2, 1Delay 300cswp=cswp+1If jqaj>0 ThenFor 10KeyPress jqaj, 1Delay 300NextEnd IfIf csaj>0 ThenIf cswp>10 ThenFor 3IfColor 566,38,"8DEDFF",0 ThenElseKeyPress "I", 1Delay 1000End IfNextKeyPress csaj, 1Delay 300Call 出售物品()cswp=0End IfEnd IfFor 3IfColor 316,271,"484849",0 ThenElseKeyPress "Esc", 1Delay 1000End IfNextMoveTo 316, 396LeftClick 3Delay 5000End SubSub 出售物品()MoveTo 547, 353LeftClick 1Delay 300MoveTo 356, 207LeftClick 3Delay 1000zby=234For 2zbx=347For 7MoveTo zbx, zbyDelay 500FindPic 325,0,640,480,"Attachment:\金币.bmp",1,ux,uyIf ux > 0 And uy > 0 ThenFindPic 325,0,640,480,"Attachment:\封装.bmp",1,ux,uyIf ux > 0 And uy > 0 ThenElseFindPic 325,0,640,480,"Attachment:\无法.bmp",1,ux,uyIf ux > 0 And uy > 0 ThenElseLeftClick 1Delay 500LeftClick 1Delay 500End IfEnd IfElseFindPic 325,0,640,480,"Attachment:\无法.bmp",1,ux,uyIf ux > 0 And uy > 0 ThenElseGoto 出售物品End IfEnd Ifzbx=zbx+30Nextzby=zby+30NextRem 出售物品MoveTo 403, 207LeftClick 3Delay 1000FindPic 0,0,640,480,"Attachment:\魔盒.bmp",0.9,ux,uyIf ux > 0 And uy > 0 ThenMoveTo ux+6, uy+12LeftClick 1Delay 500LeftClick 1Delay 500LeftClick 1End IfDelay 300KeyPress "Esc", 1Delay 300End SubSub 报警提醒()Rem 报警提醒If bjfs=0 ThenFor 2BeepDelay 1000NextEnd ifIf bjfs=1 ThenPath = Plugin.Sys.GetDir(0)Path=Path & "\W.wav"Call Plugin.Media.Play(Path)Delay 2000End ifGoto 报警提醒End Sub。

相关主题