public void TeamFormationChange1(DmAe dmae, Mouse mouse, ref BaseData.UserBattleInfo userbattleinfo) { //单独补给 //换成打手编队 TeamFormationChangeToFighter(dmae, userbattleinfo.TaskMianTeam, 1); }
public void EquipmentUpdate(DmAe dmae, int equipmentType, int equipmentPostion, int equipmentcount) { //点击研发按钮 im.mouse.ClickHomeResearch(dmae); //点击装备强化 im.mouse.ClickEquipmentStrengthen(dmae); //选择装备 im.mouse.ClickEquipmentSelect(dmae); //打开装备类型面板 im.mouse.ClickEquipmentTab(dmae); //选择装备类型 im.mouse.ClickEquipmentType(dmae, equipmentType); //关闭装备面板 im.mouse.ClickEquipmentTabToClose(dmae); //点击添加 im.mouse.ClickEquipmentToUpdate(dmae, equipmentPostion); //点击强化按钮 加号 //im.mouse.ClickEquipmentADDButton(dmae); //点击所有2星装备 im.mouse.ClickAll2Start(dmae, equipmentcount); //点击确定 //im.mouse.ClickEquipmentConfirm(dmae); //点击确定强化 im.mouse.ClickEquipmentUpdateConfirmButton(dmae); //点击返回基地 im.mouse.LeftClickBackHome(dmae); }
public void VoteDormitoryLoop(DmAe dmae) { bool Loop = true; im.mouse.ClickHomeDormitory(dmae); while (Loop) { //点击参观他人宿舍 im.mouse.ClickVisitDormitory(dmae); im.mouse.delayTime(1); //点击我的好友 im.mouse.ClickMyFriendsList(dmae); im.mouse.delayTime(1); //点击随机参观 im.mouse.ClickRandomVisit(dmae); im.mouse.delayTime(1); //点赞 //获得奖励 Loop = im.mouse.ClickVote(dmae); im.mouse.delayTime(1); //返回宿舍 im.mouse.ClickBackTOmyDormitory(dmae); im.mouse.delayTime(1); //判断是否重复 } //若结束则返回主页 im.mouse.ClickBackToHomeFromDomitory(dmae); im.mouse.delayTime(1); }
public bool ComPFriendName(DmAe dmae, string name) { object intX, intY; while (im.pagecheck.CheckMyFriendDormitory(dmae.dm) == -1) { im.mouse.delayTime(1); } if (dmae.FindPic(899, 14, 1066, 51, name, "000000", 0.9, 0, out intX, out intY) != -1) { return(true); } return(false); }
public bool ComPFirstFriendName(DmAe dmae) { object intX, intY; while (im.pagecheck.CheckMyFriendDormitory(dmae.dm) == -1) { im.mouse.delayTime(1); } if (dmae.FindPic(899, 14, 1066, 51, "\\FriendList\\temp0.bmp", "000000", 0.9, 0, out intX, out intY) != -1) { return(true); } return(false); }
public string GetMyLogFriendName(DmAe dmae) { int i = 1; string Name = ""; while (i < 100) { if (File.Exists(Application.StartupPath + "\\FriendList\\NO" + i.ToString() + ".bmp")) { Name = Name + "\\FriendList\\NO" + i.ToString() + ".bmp|"; } i++; } Name = Name.Remove(Name.Length - 1, 1); return(Name); }
public void SaveFriendName(DmAe dmae, int count, string type = "normal") { while (im.pagecheck.CheckMyFriendDormitory(dmae.dm) == -1) { im.mouse.delayTime(1); } while (im.pagecheck.CheckDormitoryLoad(dmae.dm) == false) { im.mouse.delayTime(1); } if (type == "firstname") { dmae.Capture(900, 15, 1065, 50, "\\FriendList\\temp0.bmp"); } int dm_retsave = dmae.Capture(900, 15, 1065, 50, "\\FriendList\\" + "temp" + count.ToString() + ".bmp"); }
public void TeamFormationChangeToFighter(DmAe dmae, string mainteam, int x) { im.mouse.ClickTeam(dmae); im.time.Team_S(dmae, im.mouse, mainteam, 1); im.mouse.ClickFormationTeamPresetButton(dmae); //编队页面下点击编队预设按钮 im.mouse.ClickFormationPostionPreset(dmae); //阵型页面下点击梯队预设 im.mouse.ClickFormationTeamPresetTeam(dmae, x); //点击预设梯队 im.mouse.ClickFormationTeamUsePresets(dmae); //点击套用梯队 im.mouse.ClickFormationChangeWindowINFO(dmae); //处理警告窗口 im.mouse.ClickFormationSelectedFinishButton(dmae); //点击确定 im.mouse.LeftClickBackHome(dmae); //回首页 }
public void ReadAndSaveFriendsDormitoryList(DmAe dmae) { int count = 1; object intX = 0, intY = 0; im.mouse.ClickHomeDormitory(dmae); //点击参观他人宿舍 im.mouse.ClickVisitDormitory(dmae); im.mouse.delayTime(1); //点击我的好友 im.mouse.ClickMyFriendsList(dmae); im.mouse.delayTime(1); //点击第一位 im.mouse.ClickFirstFriendsDormitory(dmae); //保存好友名字 用做终止 //做好延迟 while (true) { //保存图片 if (count == 1) { SaveFriendName(dmae, count, "firstname"); } SaveFriendName(dmae, count); im.Form1.imageList1.Images.Add(Image.FromFile(Application.StartupPath + "\\FriendList\\" + "temp" + count.ToString() + ".bmp")); if (im.Form1.pictureBox1.Image != null) { //有图片 } else { im.Form1.pictureBox1.Image = im.Form1.imageList1.Images[0]; //无图片 } count++; //点击NEXT im.mouse.ClickNextFriendDormitory(dmae); //如果当前名字和temp一样则退出循环 if (ComPFirstFriendName(dmae) == true) { break; } } File.Delete(Application.StartupPath + @"\FriendList\temp0.bmp"); im.mouse.ClickBackTOmyDormitory(dmae); //若结束则返回主页 im.mouse.ClickBackToHomeFromDomitory(dmae); im.mouse.delayTime(1); }
public void GetFriendBattery(DmAe dmae, bool NeedSecondTime, bool NeetTOCap = true) { object intX = 0, intY = 0; bool FirstName = true; bool secondtime = false; string Name = GetMyLogFriendName(dmae); im.mouse.ClickHomeDormitory(dmae); //点击参观他人宿舍 im.mouse.ClickVisitDormitory(dmae); im.mouse.delayTime(1); //点击我的好友 im.mouse.ClickMyFriendsList(dmae); im.mouse.delayTime(1); //点击第一位 im.mouse.ClickFirstFriendsDormitory(dmae); //保存好友名字 用做终止 //做好延迟 while (true) { while (im.pagecheck.CheckDormitoryLoad(dmae.dm) == false) { im.mouse.delayTime(1); } //保存图片 if (FirstName) { SaveFriendName(dmae, 0, "firstname"); FirstName = false; } //开始比较如果名字符合则检查是否有电池 //重置镜头 im.mouse.ClickRestDormitoryMLeft(dmae); //对比名字 if (ComPFriendName(dmae, Name) == true) { //确认到名字 //检查电池 if (im.pagecheck.CheckFriendDormitoryBattery(dmae.dm) == true) { im.mouse.ClickFriendDormitoryBattery(dmae); im.mouse.ClickFriendDormitoryBatteryWindow(dmae); } } //二次循环 if (im.pagecheck.CheckFriendDormitoryBattery(dmae.dm) == true && secondtime == true) { im.mouse.ClickFriendDormitoryBattery(dmae); im.mouse.ClickFriendDormitoryBatteryWindow(dmae); } //点击NEXT im.mouse.ClickNextFriendDormitory(dmae); //如果当前名字和temp一样则退出循环 //二次循环检查 if (ComPFirstFriendName(dmae) == true && secondtime == true) { break; } if (ComPFirstFriendName(dmae) == true && secondtime == false) { SystemInfo.AppState = "二次循环"; if (NeedSecondTime == true) { secondtime = true; } else { break; } } } //删除第一张图片临时图片 File.Delete(Application.StartupPath + @"\FriendList\temp0.bmp"); im.mouse.ClickBackTOmyDormitory(dmae); //若结束则返回主页 im.mouse.ClickBackToHomeFromDomitory(dmae); im.mouse.delayTime(1); }
public void EndAtBattle(DmAe dmae) { this.BattleLoopTime++; if (this.Team_Serror) { this.BattleFixTime = this.Team_SerrorTime; return; } if (this.NeedToFix) { CommonHelp.BattleFixNumber = Key + 1; CommonHelp.gametasklist.Insert(0, TaskList.Fix); if (this.BattleSupport_plus == true) { if (this.BattleLoopTime % this.BattleSupportRound == 0) { CommonHelp.gametasklist.Insert(1, TaskList.BattleTeamFormationChange1); CommonHelp.gametasklist.Insert(2, TaskList.BattleSupport_plus); CommonHelp.gametasklist.Insert(3, TaskList.BattleTeamFormationChange2); if (this.BattleSupport_plus == true) { this.NeedSupport_plus = true; } } } } else //-----循环间隔 { CommonHelp.BattleFixNumber = Key + 1; if (this.BattleSupport_plus == true) { if (this.BattleLoopTime % this.BattleSupportRound == 0) { CommonHelp.gametasklist.Insert(0, TaskList.BattleTeamFormationChange1); CommonHelp.gametasklist.Insert(1, TaskList.BattleSupport_plus); CommonHelp.gametasklist.Insert(2, TaskList.BattleTeamFormationChange2); if (this.BattleSupport_plus == true) { this.NeedSupport_plus = true; } } } Random ran = new Random(); int temp0 = ran.Next(0, this.RoundInterval); this.BattleFixTime = temp0 + 1; } if (this.BattleLoopTime == this.LoopMaxTime) { this.BattleLoopTime = 0; this.BattleFixTime = -1; this.Used = false; } if (this.Used == false) { CommonHelp.BindWindowS(dmae, 0); } if (this.BattleLoopUnLockWindows == false) { CommonHelp.BindWindowS(dmae, 0); } }
public void TeamFormationChange2(DmAe dmae, Mouse mouse, ref BaseData.UserBattleInfo userbattleinfo) { //换成完整梯队 TeamFormationChangeToFighter(dmae, userbattleinfo.TaskMianTeam, 2); //over }
public void TeamFormationFighterSupport(DmAe dmae, Mouse mouse, ref BaseData.UserBattleInfo userbattleinfo) { im.time.ChoseThebattle(dmae, mouse, ref userbattleinfo); }