DerpProgrammer
Community Developer
- Joined
- Mar 16, 2015
- Messages
- 33
- Reaction score
- 0
Here is a Divine Blessings Coin Retreiver plugin that uses the new getScheduleItems() functionality Out recently implemented.
This plugin can be configured for auto-start.
It just retreives the Divine Blessings Coin, if it is available, then waits until the next one is available.
This plugin can be configured for auto-start.
It just retreives the Divine Blessings Coin, if it is available, then waits until the next one is available.
PHP:
using System;
using System.Drawing;
using System.Windows.Forms;
using System.Threading;
using System.Collections.Generic;
using System.Linq;
using ArcheBuddy.Bot.Classes;
namespace DefaultNameSpace{
public class DefaultClass : Core
{
public static string GetPluginAuthor()
{
return "DerpProgrammer";
}
public static string GetPluginVersion()
{
return "1.0.0.0";
}
public static string GetPluginDescription()
{
return "Divine Blessings Coin Retriever";
}
//Call on plugin start
public void PluginRun()
{
ClearLogs();
while (gameState != GameState.Ingame)Thread.Sleep(10000);
while (gameState == GameState.Ingame || gameState == GameState.LoadingGameWorld)
{
foreach (var i in getScheduleItems())
{
if (i != null)
{
if (i.db.name == "Divine Clock" && i.remainTime == 0 && i.totalReceivedCount < 12)
{
i.Claim();
Log ("Claimed Divine Blessings Coin number: " + i.totalReceivedCount.ToString());
Thread.Sleep(1000);
}
if (i.db.name == "Divine Clock") Log("Waiting " + (i.remainTime/60).ToString() + " minutes to get the next Divine Coin.");
Thread.Sleep(i.remainTime*1000);
}
Thread.Sleep(1000);
}
}
}
//Call on plugin stop
public void PluginStop()
{
}
}
}