2023-04-20 21:39:08 -07:00
|
|
|
|
using System;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.Drawing;
|
|
|
|
|
using System.Linq;
|
|
|
|
|
using System.Text;
|
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
|
using System.Windows.Forms;
|
2024-04-05 21:50:39 -07:00
|
|
|
|
using static app.MapAreaStruc;
|
2023-04-20 21:39:08 -07:00
|
|
|
|
|
|
|
|
|
namespace app
|
|
|
|
|
{
|
|
|
|
|
public class Baal
|
|
|
|
|
{
|
|
|
|
|
Form1 Form1_0;
|
|
|
|
|
|
|
|
|
|
public int CurrentStep = 0;
|
2024-03-29 00:19:36 -07:00
|
|
|
|
public bool ScriptDone = false;
|
2024-04-05 21:50:39 -07:00
|
|
|
|
public bool DetectedBaal = false;
|
2023-04-27 20:42:59 -07:00
|
|
|
|
|
|
|
|
|
public List<long> IgnoredMobs = new List<long>();
|
2024-03-29 00:19:36 -07:00
|
|
|
|
|
2024-04-05 21:50:39 -07:00
|
|
|
|
public Position ThronePos = new Position { X = 15095, Y = 5029 };
|
|
|
|
|
public Position PortalPos = new Position { X = 15116, Y = 5071 };
|
|
|
|
|
|
|
|
|
|
public bool Wave5Detected = false;
|
|
|
|
|
public bool Wave5Cleared = false;
|
|
|
|
|
|
|
|
|
|
public Position ThroneCorner1Pos = new Position { X = 15104, Y = 5062 };
|
|
|
|
|
public Position ThroneCorner2Pos = new Position { X = 15082, Y = 5063 };
|
|
|
|
|
public Position ThroneCorner3Pos = new Position { X = 15081, Y = 5016 };
|
|
|
|
|
public Position ThroneCorner4Pos = new Position { X = 15112, Y = 5013 };
|
2024-03-29 00:19:36 -07:00
|
|
|
|
|
2024-04-05 21:50:39 -07:00
|
|
|
|
public int CornerClearedIndex = 0;
|
|
|
|
|
public int BufferPathFindingMoveSize = 0;
|
|
|
|
|
|
|
|
|
|
public DateTime TimeSinceLastWaveDone = DateTime.Now;
|
|
|
|
|
public bool TimeSinceLastWaveSet = false;
|
2023-04-20 21:39:08 -07:00
|
|
|
|
|
|
|
|
|
public void SetForm1(Form1 form1_1)
|
|
|
|
|
{
|
|
|
|
|
Form1_0 = form1_1;
|
|
|
|
|
}
|
|
|
|
|
|
2024-04-05 21:50:39 -07:00
|
|
|
|
public void ResetVars()
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
|
|
|
|
CurrentStep = 0;
|
2024-03-29 00:19:36 -07:00
|
|
|
|
ScriptDone = false;
|
2024-04-05 21:50:39 -07:00
|
|
|
|
DetectedBaal = false;
|
|
|
|
|
Wave5Detected = false;
|
|
|
|
|
Wave5Cleared = false;
|
|
|
|
|
IgnoredMobs = new List<long>();
|
|
|
|
|
CornerClearedIndex = 0;
|
|
|
|
|
TimeSinceLastWaveDone = DateTime.Now;
|
|
|
|
|
TimeSinceLastWaveSet = false;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public void DetectCurrentStep()
|
|
|
|
|
{
|
|
|
|
|
if ((Enums.Area)Form1_0.PlayerScan_0.levelNo == Enums.Area.TheWorldStoneKeepLevel2) CurrentStep = 1;
|
|
|
|
|
if ((Enums.Area)Form1_0.PlayerScan_0.levelNo == Enums.Area.TheWorldStoneKeepLevel3) CurrentStep = 2;
|
|
|
|
|
if ((Enums.Area)Form1_0.PlayerScan_0.levelNo == Enums.Area.ThroneOfDestruction) CurrentStep = 3;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public void RunScript()
|
|
|
|
|
{
|
2024-04-14 18:51:35 -07:00
|
|
|
|
Form1_0.Town_0.ScriptTownAct = 5; //set to town act 4 when running this script
|
2024-04-05 21:50:39 -07:00
|
|
|
|
|
|
|
|
|
if (!Form1_0.Running || !Form1_0.GameStruc_0.IsInGame())
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
2024-04-05 21:50:39 -07:00
|
|
|
|
ScriptDone = true;
|
|
|
|
|
return;
|
2023-04-20 21:39:08 -07:00
|
|
|
|
}
|
|
|
|
|
|
2024-04-05 21:50:39 -07:00
|
|
|
|
if (Form1_0.Town_0.GetInTown())
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
2024-04-05 21:50:39 -07:00
|
|
|
|
Form1_0.SetGameStatus("GO TO WP");
|
|
|
|
|
CurrentStep = 0;
|
2023-04-20 21:39:08 -07:00
|
|
|
|
|
2024-04-05 21:50:39 -07:00
|
|
|
|
Form1_0.Town_0.GoToWPArea(5, 8);
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
if (CurrentStep == 0)
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
2024-04-05 21:50:39 -07:00
|
|
|
|
Form1_0.SetGameStatus("DOING BAAL");
|
|
|
|
|
Form1_0.Battle_0.CastDefense();
|
2024-04-14 18:51:35 -07:00
|
|
|
|
//Form1_0.WaitDelay(15);
|
2023-04-27 20:42:59 -07:00
|
|
|
|
|
2024-04-05 21:50:39 -07:00
|
|
|
|
if (Form1_0.PlayerScan_0.levelNo == (int)Enums.Area.TheWorldStoneKeepLevel2)
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
2024-04-05 21:50:39 -07:00
|
|
|
|
CurrentStep++;
|
2023-04-20 21:39:08 -07:00
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
2024-04-05 21:50:39 -07:00
|
|
|
|
DetectCurrentStep();
|
|
|
|
|
if (CurrentStep == 0) Form1_0.Town_0.GoToTown();
|
2023-04-20 21:39:08 -07:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2024-04-05 21:50:39 -07:00
|
|
|
|
if (CurrentStep == 1)
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
2024-04-14 18:51:35 -07:00
|
|
|
|
//####
|
|
|
|
|
if (Form1_0.PlayerScan_0.levelNo == (int)Enums.Area.TheWorldStoneKeepLevel3)
|
|
|
|
|
{
|
|
|
|
|
CurrentStep++;
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
//####
|
|
|
|
|
|
2024-04-05 21:50:39 -07:00
|
|
|
|
Form1_0.PathFinding_0.MoveToExit(Enums.Area.TheWorldStoneKeepLevel3);
|
|
|
|
|
CurrentStep++;
|
2023-04-20 21:39:08 -07:00
|
|
|
|
}
|
|
|
|
|
|
2024-04-05 21:50:39 -07:00
|
|
|
|
if (CurrentStep == 2)
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
2024-04-14 18:51:35 -07:00
|
|
|
|
//####
|
|
|
|
|
if (Form1_0.PlayerScan_0.levelNo == (int)Enums.Area.ThroneOfDestruction)
|
|
|
|
|
{
|
|
|
|
|
CurrentStep++;
|
|
|
|
|
return;
|
|
|
|
|
}
|
2024-04-05 21:50:39 -07:00
|
|
|
|
if ((Enums.Area)Form1_0.PlayerScan_0.levelNo == Enums.Area.TheWorldStoneKeepLevel2)
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
2024-04-05 21:50:39 -07:00
|
|
|
|
CurrentStep--;
|
|
|
|
|
return;
|
2023-04-20 21:39:08 -07:00
|
|
|
|
}
|
2024-04-14 18:51:35 -07:00
|
|
|
|
//####
|
2024-03-29 00:19:36 -07:00
|
|
|
|
|
2024-04-05 21:50:39 -07:00
|
|
|
|
Form1_0.PathFinding_0.MoveToExit(Enums.Area.ThroneOfDestruction);
|
|
|
|
|
Form1_0.Town_0.TPSpawned = false;
|
|
|
|
|
CurrentStep++;
|
2023-04-27 20:42:59 -07:00
|
|
|
|
}
|
|
|
|
|
|
2024-04-05 21:50:39 -07:00
|
|
|
|
if (CurrentStep == 3)
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
2024-04-14 18:51:35 -07:00
|
|
|
|
//####
|
2024-04-05 21:50:39 -07:00
|
|
|
|
if (Form1_0.PlayerScan_0.levelNo == (int)Enums.Area.TheWorldStoneKeepLevel3)
|
2024-03-29 00:19:36 -07:00
|
|
|
|
{
|
2024-04-05 21:50:39 -07:00
|
|
|
|
CurrentStep--;
|
|
|
|
|
return;
|
2024-03-29 00:19:36 -07:00
|
|
|
|
}
|
2024-04-14 18:51:35 -07:00
|
|
|
|
//####
|
2024-03-29 00:19:36 -07:00
|
|
|
|
|
2024-04-05 21:50:39 -07:00
|
|
|
|
if (Form1_0.PublicGame && !Form1_0.Town_0.TPSpawned)
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
2024-04-05 21:50:39 -07:00
|
|
|
|
Form1_0.PathFinding_0.MoveToThisPos(PortalPos);
|
|
|
|
|
Form1_0.Town_0.SpawnTP();
|
2023-04-20 21:39:08 -07:00
|
|
|
|
}
|
2024-04-05 21:50:39 -07:00
|
|
|
|
|
|
|
|
|
Form1_0.PathFinding_0.MoveToThisPos(ThronePos);
|
|
|
|
|
CurrentStep++;
|
2023-04-20 21:39:08 -07:00
|
|
|
|
}
|
2024-04-05 21:50:39 -07:00
|
|
|
|
|
|
|
|
|
if (CurrentStep == 4)
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
2024-04-05 21:50:39 -07:00
|
|
|
|
//clear throne area of mobs
|
|
|
|
|
if (CornerClearedIndex == 0)
|
2023-04-27 20:42:59 -07:00
|
|
|
|
{
|
2024-04-05 21:50:39 -07:00
|
|
|
|
Form1_0.PathFinding_0.MoveToThisPos(ThroneCorner1Pos, 4, true);
|
|
|
|
|
CornerClearedIndex++;
|
2023-04-27 20:42:59 -07:00
|
|
|
|
}
|
2024-04-05 21:50:39 -07:00
|
|
|
|
else if (CornerClearedIndex == 1)
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
2024-04-05 21:50:39 -07:00
|
|
|
|
Form1_0.PathFinding_0.MoveToThisPos(ThroneCorner2Pos, 4, true);
|
|
|
|
|
CornerClearedIndex++;
|
2023-04-20 21:39:08 -07:00
|
|
|
|
}
|
2024-04-05 21:50:39 -07:00
|
|
|
|
else if (CornerClearedIndex == 2)
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
2024-04-05 21:50:39 -07:00
|
|
|
|
Form1_0.PathFinding_0.MoveToThisPos(ThroneCorner4Pos, 4, true);
|
|
|
|
|
CornerClearedIndex++;
|
2023-04-20 21:39:08 -07:00
|
|
|
|
}
|
2024-04-05 21:50:39 -07:00
|
|
|
|
else if (CornerClearedIndex == 3)
|
2024-03-29 00:19:36 -07:00
|
|
|
|
{
|
2024-04-05 21:50:39 -07:00
|
|
|
|
Form1_0.PathFinding_0.MoveToThisPos(ThroneCorner3Pos, 4, true);
|
|
|
|
|
CornerClearedIndex++;
|
2023-04-20 21:39:08 -07:00
|
|
|
|
}
|
2024-04-05 21:50:39 -07:00
|
|
|
|
if (CornerClearedIndex == 4)
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
2024-04-05 21:50:39 -07:00
|
|
|
|
//Form1_0.PathFinding_0.MoveToThisPos(ThroneCorner4Pos, 4, true);
|
2023-04-20 21:39:08 -07:00
|
|
|
|
CurrentStep++;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2024-04-05 21:50:39 -07:00
|
|
|
|
if (CurrentStep == 5)
|
|
|
|
|
{
|
|
|
|
|
//clear waves
|
2024-04-14 18:51:35 -07:00
|
|
|
|
if (Form1_0.PlayerScan_0.xPosFinal < ThronePos.X - 4
|
|
|
|
|
|| Form1_0.PlayerScan_0.xPosFinal > ThronePos.X + 4
|
|
|
|
|
|| Form1_0.PlayerScan_0.yPosFinal < ThronePos.Y - 4
|
|
|
|
|
|| Form1_0.PlayerScan_0.yPosFinal > ThronePos.Y + 4)
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
2024-04-14 18:51:35 -07:00
|
|
|
|
if (!Form1_0.Battle_0.ClearingArea && !Form1_0.Battle_0.DoingBattle)
|
|
|
|
|
{
|
|
|
|
|
Form1_0.PathFinding_0.MoveToThisPos(ThronePos, 2, true);
|
|
|
|
|
}
|
2023-04-20 21:39:08 -07:00
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
2024-04-05 21:50:39 -07:00
|
|
|
|
Form1_0.Battle_0.DoBattleScript(30);
|
2023-04-20 21:39:08 -07:00
|
|
|
|
}
|
|
|
|
|
|
2024-04-05 21:50:39 -07:00
|
|
|
|
if (!Wave5Cleared)
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
2024-04-14 18:51:35 -07:00
|
|
|
|
if (Form1_0.PublicGame && Form1_0.PlayerScan_0.HasAnyPlayerInArea((int)Enums.Area.TheWorldstoneChamber))
|
|
|
|
|
{
|
|
|
|
|
Form1_0.method_1("People detected in Worldstone chamber, switching to baal script!", Color.Red);
|
|
|
|
|
CurrentStep++;
|
|
|
|
|
}
|
|
|
|
|
|
2024-04-05 21:50:39 -07:00
|
|
|
|
//DETECT OTHERS WAVES FOR CASTING
|
|
|
|
|
if (!TimeSinceLastWaveSet && !Form1_0.MobsStruc_0.GetMobs("", "", true, 25, IgnoredMobs))
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
2024-04-05 21:50:39 -07:00
|
|
|
|
TimeSinceLastWaveDone = DateTime.Now;
|
|
|
|
|
TimeSinceLastWaveSet = true;
|
2024-04-14 18:51:35 -07:00
|
|
|
|
Form1_0.InventoryStruc_0.DumpBadItemsOnGround();
|
2023-04-20 21:39:08 -07:00
|
|
|
|
}
|
2024-04-05 21:50:39 -07:00
|
|
|
|
|
|
|
|
|
//START CASTING IN ADVANCE
|
|
|
|
|
if ((DateTime.Now - TimeSinceLastWaveDone).TotalSeconds > 3)
|
2023-04-27 20:42:59 -07:00
|
|
|
|
{
|
2024-04-05 21:50:39 -07:00
|
|
|
|
Form1_0.Battle_0.SetSkills();
|
|
|
|
|
Form1_0.Battle_0.CastSkills();
|
2023-04-27 20:42:59 -07:00
|
|
|
|
}
|
2024-04-05 21:50:39 -07:00
|
|
|
|
|
|
|
|
|
//STOP CASTING
|
|
|
|
|
if (Form1_0.MobsStruc_0.GetMobs("", "", true, 25, IgnoredMobs))
|
2023-04-27 20:42:59 -07:00
|
|
|
|
{
|
2024-04-05 21:50:39 -07:00
|
|
|
|
TimeSinceLastWaveDone = DateTime.Now;
|
|
|
|
|
TimeSinceLastWaveSet = false;
|
2024-04-14 18:51:35 -07:00
|
|
|
|
Form1_0.Battle_0.DoBattleScript(30);
|
2023-04-27 20:42:59 -07:00
|
|
|
|
}
|
|
|
|
|
|
2024-04-05 21:50:39 -07:00
|
|
|
|
//#### DETECT WAVE 5
|
|
|
|
|
if (Form1_0.MobsStruc_0.GetMobs("getSuperUniqueName", "Baal Subject 5", false, 99, IgnoredMobs))
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
2024-04-05 21:50:39 -07:00
|
|
|
|
if (Form1_0.MobsStruc_0.MobsHP > 0)
|
|
|
|
|
{
|
|
|
|
|
Wave5Detected = true;
|
|
|
|
|
}
|
2024-04-14 18:51:35 -07:00
|
|
|
|
else
|
|
|
|
|
{
|
2024-04-05 21:50:39 -07:00
|
|
|
|
if (Wave5Detected)
|
|
|
|
|
{
|
|
|
|
|
if (!Form1_0.MobsStruc_0.GetMobs("", "", true, 25, IgnoredMobs))
|
|
|
|
|
{
|
|
|
|
|
Wave5Cleared = true;
|
|
|
|
|
}
|
2024-04-14 18:51:35 -07:00
|
|
|
|
}
|
2024-04-05 21:50:39 -07:00
|
|
|
|
}
|
2023-04-20 21:39:08 -07:00
|
|
|
|
}
|
2024-04-05 21:50:39 -07:00
|
|
|
|
//####
|
2023-04-20 21:39:08 -07:00
|
|
|
|
}
|
2024-04-05 21:50:39 -07:00
|
|
|
|
else
|
2024-03-29 00:19:36 -07:00
|
|
|
|
{
|
|
|
|
|
CurrentStep++;
|
|
|
|
|
}
|
2023-04-20 21:39:08 -07:00
|
|
|
|
}
|
2024-04-05 21:50:39 -07:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (CurrentStep == 6)
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
|
|
|
|
Form1_0.SetGameStatus("WAITING PORTAL");
|
2023-04-27 20:42:59 -07:00
|
|
|
|
|
2023-04-20 21:39:08 -07:00
|
|
|
|
//move to baal red portal
|
|
|
|
|
if (Form1_0.PlayerScan_0.xPosFinal >= 15170 - 40
|
|
|
|
|
&& Form1_0.PlayerScan_0.xPosFinal <= 15170 + 40
|
|
|
|
|
&& Form1_0.PlayerScan_0.yPosFinal >= 5880 - 40
|
|
|
|
|
&& Form1_0.PlayerScan_0.yPosFinal <= 5880 + 40)
|
|
|
|
|
{
|
2024-04-14 18:51:35 -07:00
|
|
|
|
//Form1_0.Battle_0.CastDefense();
|
2023-04-20 21:39:08 -07:00
|
|
|
|
CurrentStep++;
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
if (Form1_0.PlayerScan_0.xPosFinal < 15090 - 3
|
|
|
|
|
|| Form1_0.PlayerScan_0.xPosFinal > 15090 + 3
|
|
|
|
|
|| Form1_0.PlayerScan_0.yPosFinal < 5008 - 3
|
|
|
|
|
|| Form1_0.PlayerScan_0.yPosFinal > 5008 + 3)
|
|
|
|
|
{
|
|
|
|
|
if (!CharConfig.UseTeleport)
|
|
|
|
|
{
|
|
|
|
|
Form1_0.Mover_0.MoveAcceptOffset = 1;
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
Form1_0.Mover_0.MoveAcceptOffset = 3;
|
|
|
|
|
}
|
|
|
|
|
if (Form1_0.Mover_0.MoveToLocation(15095, 5023))
|
|
|
|
|
{
|
|
|
|
|
if (Form1_0.Mover_0.MoveToLocation(15090, 5008))
|
|
|
|
|
{
|
2024-03-29 00:19:36 -07:00
|
|
|
|
Form1_0.Battle_0.CastDefense();
|
2023-04-20 21:39:08 -07:00
|
|
|
|
Form1_0.Mover_0.MoveAcceptOffset = 4;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
Dictionary<string, int> itemScreenPos = Form1_0.GameStruc_0.World2Screen(Form1_0.PlayerScan_0.xPosFinal, Form1_0.PlayerScan_0.yPosFinal, 15091, 5005);
|
|
|
|
|
Form1_0.KeyMouse_0.MouseClicc(itemScreenPos["x"] - 5, itemScreenPos["y"] - 20);
|
|
|
|
|
Form1_0.WaitDelay(10);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
2024-04-05 21:50:39 -07:00
|
|
|
|
|
|
|
|
|
if (CurrentStep == 7)
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
|
|
|
|
Form1_0.SetGameStatus("MOVING TO BAAL");
|
2024-04-14 18:51:35 -07:00
|
|
|
|
Form1_0.PathFinding_0.MoveToThisPos(new Position { X = 15134, Y = 5920 });
|
|
|
|
|
//Form1_0.WaitDelay(50); //wait a bit to detect baal
|
2024-04-05 21:50:39 -07:00
|
|
|
|
CurrentStep++;
|
2023-04-20 21:39:08 -07:00
|
|
|
|
}
|
2024-04-05 21:50:39 -07:00
|
|
|
|
|
|
|
|
|
if (CurrentStep == 8)
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
2023-04-27 20:42:59 -07:00
|
|
|
|
Form1_0.Potions_0.CanUseSkillForRegen = false;
|
2023-04-20 21:39:08 -07:00
|
|
|
|
Form1_0.SetGameStatus("KILLING BAAL");
|
2024-03-29 00:19:36 -07:00
|
|
|
|
if (Form1_0.MobsStruc_0.GetMobs("getBossName", "Baal", false, 200, new List<long>()))
|
2023-04-20 21:39:08 -07:00
|
|
|
|
{
|
|
|
|
|
if (Form1_0.MobsStruc_0.MobsHP > 0)
|
|
|
|
|
{
|
2023-04-27 20:42:59 -07:00
|
|
|
|
DetectedBaal = true;
|
2023-04-20 21:39:08 -07:00
|
|
|
|
Form1_0.Battle_0.RunBattleScriptOnThisMob("getBossName", "Baal");
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
2024-04-14 18:51:35 -07:00
|
|
|
|
if (!Form1_0.ItemsStruc_0.GetItems(true)) Form1_0.WaitDelay(5);
|
|
|
|
|
if (!Form1_0.ItemsStruc_0.GetItems(true)) Form1_0.WaitDelay(5);
|
|
|
|
|
if (!Form1_0.ItemsStruc_0.GetItems(true)) Form1_0.WaitDelay(5);
|
|
|
|
|
if (!Form1_0.ItemsStruc_0.GetItems(true)) Form1_0.WaitDelay(5);
|
|
|
|
|
if (!Form1_0.ItemsStruc_0.GetItems(true)) Form1_0.WaitDelay(5);
|
|
|
|
|
if (!Form1_0.ItemsStruc_0.GetItems(true)) Form1_0.WaitDelay(5);
|
|
|
|
|
if (!Form1_0.ItemsStruc_0.GetItems(true)) Form1_0.WaitDelay(5);
|
|
|
|
|
if (!Form1_0.ItemsStruc_0.GetItems(true)) Form1_0.WaitDelay(5);
|
|
|
|
|
if (!Form1_0.ItemsStruc_0.GetItems(true)) Form1_0.WaitDelay(5);
|
|
|
|
|
if (!Form1_0.ItemsStruc_0.GetItems(true)) Form1_0.WaitDelay(5);
|
|
|
|
|
//if (!Form1_0.PublicGame) Form1_0.ItemsStruc_0.GrabAllItemsForGold();
|
2023-04-20 21:39:08 -07:00
|
|
|
|
Form1_0.ItemsStruc_0.GrabAllItemsForGold();
|
2024-04-14 18:51:35 -07:00
|
|
|
|
|
|
|
|
|
Form1_0.Battle_0.ClearingArea = false;
|
|
|
|
|
Form1_0.Battle_0.DoingBattle = false;
|
2023-04-27 20:42:59 -07:00
|
|
|
|
Form1_0.Potions_0.CanUseSkillForRegen = true;
|
2024-04-05 21:50:39 -07:00
|
|
|
|
//Form1_0.LeaveGame(true);
|
|
|
|
|
Form1_0.Town_0.UseLastTP = false;
|
2024-03-29 00:19:36 -07:00
|
|
|
|
ScriptDone = true;
|
2023-04-20 21:39:08 -07:00
|
|
|
|
}
|
|
|
|
|
}
|
2023-04-27 20:42:59 -07:00
|
|
|
|
else
|
|
|
|
|
{
|
2024-03-29 00:19:36 -07:00
|
|
|
|
Form1_0.method_1("Baal not detected!", Color.Red);
|
|
|
|
|
|
2024-04-14 18:51:35 -07:00
|
|
|
|
for (int i = 0; i < 140; i++)
|
|
|
|
|
{
|
|
|
|
|
Form1_0.PlayerScan_0.GetPositions();
|
|
|
|
|
|
|
|
|
|
Form1_0.Battle_0.SetSkills();
|
|
|
|
|
Form1_0.Battle_0.CastSkills();
|
|
|
|
|
|
|
|
|
|
Form1_0.ItemsStruc_0.GetItems(true);
|
|
|
|
|
Form1_0.Potions_0.CheckIfWeUsePotion();
|
|
|
|
|
Form1_0.ItemsStruc_0.GetItems(false);
|
|
|
|
|
Form1_0.overlayForm.UpdateOverlay();
|
|
|
|
|
|
|
|
|
|
if (Form1_0.MobsStruc_0.GetMobs("getBossName", "Baal", false, 200, new List<long>())) return; //redetect baal?
|
|
|
|
|
}
|
|
|
|
|
|
2023-04-27 20:42:59 -07:00
|
|
|
|
//baal not detected...
|
|
|
|
|
Form1_0.ItemsStruc_0.GetItems(true);
|
2024-03-29 00:19:36 -07:00
|
|
|
|
if (Form1_0.MobsStruc_0.GetMobs("getBossName", "Baal", false, 200, new List<long>())) return; //redetect baal?
|
2024-04-14 18:51:35 -07:00
|
|
|
|
//if (!Form1_0.PublicGame) Form1_0.ItemsStruc_0.GrabAllItemsForGold();
|
2023-04-27 20:42:59 -07:00
|
|
|
|
Form1_0.ItemsStruc_0.GrabAllItemsForGold();
|
2024-03-29 00:19:36 -07:00
|
|
|
|
if (Form1_0.MobsStruc_0.GetMobs("getBossName", "Baal", false, 200, new List<long>())) return; //redetect baal?
|
2024-04-05 21:50:39 -07:00
|
|
|
|
|
2024-04-14 18:51:35 -07:00
|
|
|
|
Form1_0.Battle_0.ClearingArea = false;
|
|
|
|
|
Form1_0.Battle_0.DoingBattle = false;
|
2023-04-27 20:42:59 -07:00
|
|
|
|
Form1_0.Potions_0.CanUseSkillForRegen = true;
|
2024-04-05 21:50:39 -07:00
|
|
|
|
//Form1_0.LeaveGame(true);
|
|
|
|
|
Form1_0.Town_0.UseLastTP = false;
|
2024-03-29 00:19:36 -07:00
|
|
|
|
ScriptDone = true;
|
2023-04-27 20:42:59 -07:00
|
|
|
|
}
|
2023-04-20 21:39:08 -07:00
|
|
|
|
}
|
2024-03-29 00:19:36 -07:00
|
|
|
|
|
|
|
|
|
}
|
2023-04-20 21:39:08 -07:00
|
|
|
|
}
|
|
|
|
|
|
2024-04-05 21:50:39 -07:00
|
|
|
|
|
2023-04-20 21:39:08 -07:00
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}
|