Quote:
Originally Posted by idol856
Why is stop on 3attemps of awake?
why its stop on 3 attemps of awakening?
|
You can change the value of 3 on this line to whatever you want and bot wont stop anymore after game returns same awake for 3 times:
if (latestAwakes.Count >= 5)
Here's the original code, source code is available in github. Just compile your own solution.:
private void AwakeningLoopThread(List<AwakeItem> preferredAwakeItemList)
{
Queue<List<Awake>> latestAwakes = new Queue<List<Awake>>();
try
{
LogHelper.AppendLog(_ui, "Bot has started");
Win32.SetForegroundWindow(_botConfig.Process.MainW indowHandle);
AwakeningResolver awakeResolver = new AwakeningResolver(_serverConfig);
while (_isRunning)
{
if (latestAwakes.Count >= 3)
{
// Check if the 3 awakes in the queue are all the same
var firstAwakes = latestAwakes.ElementAt(0);
bool anyNotEqual = false;
for (int i = 1; i < latestAwakes.Count; ++i)
{
var awakes = latestAwakes.ElementAt(i);
bool sameSize = awakes.Count == firstAwakes.Count;
if (!sameSize)
{
anyNotEqual = true;
break;
}