Adjust bot
This commit is contained in:
parent
a9e34bac15
commit
e985c5fd12
3 changed files with 32 additions and 59 deletions
|
@ -6,7 +6,7 @@ using System.Reflection;
|
|||
[assembly: AssemblyCompany("ZNI")]
|
||||
[assembly: AssemblyAlgorithmId(System.Configuration.Assemblies.AssemblyHashAlgorithm.MD5)]
|
||||
[assembly: AssemblyCopyright("© 2020 Tara Piccari")]
|
||||
[assembly: AssemblyFileVersion("5.2.011")]
|
||||
[assembly: AssemblyFileVersion("5.2.012")]
|
||||
[assembly: AssemblyDescription("Second Life Bot - BotCore5")]
|
||||
|
||||
|
||||
|
@ -15,7 +15,7 @@ namespace Bot.Assemble
|
|||
public class ASMInfo
|
||||
{
|
||||
public static string BotName = "ZBotCore";
|
||||
public static string BotVer = "5.2.011";
|
||||
public static string BotVer = "5.2.012";
|
||||
public static string GitPassword
|
||||
{
|
||||
get
|
||||
|
|
|
@ -46,7 +46,6 @@ namespace Bot
|
|||
get; set;
|
||||
}
|
||||
|
||||
public string MainProgramDLL = "";
|
||||
public string first { get; set; } = "";
|
||||
public string last { get; set; } = "";
|
||||
public string password { get; set; } = "";
|
||||
|
@ -69,7 +68,6 @@ namespace Bot
|
|||
public Dictionary<UUID, int> BotAdmins { get; set; } = new Dictionary<UUID, int>();
|
||||
|
||||
public List<string> AuthedGithubUsers { get; set; } = new List<string>();
|
||||
public List<string> LinkedDLLs { get; set; } = new List<string>();
|
||||
|
||||
public bool Authed(string GHLogin)
|
||||
{
|
||||
|
|
27
Program.cs
27
Program.cs
|
@ -23,7 +23,6 @@ namespace Bot
|
|||
public static string BotStr = ASMInfo.BotName; // internal identifier for linden
|
||||
public static string Flavor = "Bot"; // inworld identification - must be customized
|
||||
public static SerialManager SM = new SerialManager();
|
||||
public static string DefaultProgram = ""; // no default.
|
||||
public static GridClient client = new GridClient();
|
||||
public static bool g_iIsRunning = true;
|
||||
public static MessageHandler MH;
|
||||
|
@ -72,12 +71,6 @@ namespace Bot
|
|||
MainConfiguration.Instance.Save();
|
||||
return;
|
||||
}
|
||||
else if (args[0] == "-m")
|
||||
{
|
||||
MainConfiguration.Instance.MainProgramDLL = args[1];
|
||||
MainConfiguration.Instance.Save();
|
||||
return;
|
||||
}
|
||||
}
|
||||
else if (args.Length == 4)
|
||||
{
|
||||
|
@ -186,7 +179,6 @@ namespace Bot
|
|||
Log.info(false, "Now enter your password: ");
|
||||
pwd = Console.ReadLine();
|
||||
|
||||
conf.MainProgramDLL = DefaultProgram;
|
||||
conf.ConfigFor = "ZBotCore";
|
||||
conf.ConfigVersion = 1.0f;
|
||||
|
||||
|
@ -384,19 +376,6 @@ namespace Bot
|
|||
Flavor = conf.ConfigFor;
|
||||
}
|
||||
|
||||
// Check MainConfiguration for a mainProgram handle
|
||||
if (conf.MainProgramDLL == null)
|
||||
{
|
||||
Log.info(true, "Setting main program library to none");
|
||||
conf.MainProgramDLL = DefaultProgram;
|
||||
SM.Write<MainConfiguration>("Main", conf);
|
||||
|
||||
}
|
||||
if (File.Exists(conf.MainProgramDLL) == false && startupSeq)
|
||||
{
|
||||
Log.info(true, "MainProgram Library: " + conf.MainProgramDLL + " does not exist");
|
||||
|
||||
startupSeq = false;
|
||||
|
||||
registry = CommandRegistry.Instance;
|
||||
registry.LocateCommands();
|
||||
|
@ -405,9 +384,7 @@ namespace Bot
|
|||
|
||||
GroupsCache = new Dictionary<UUID, Group>();
|
||||
ReloadGroupsCache();
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
if (startupSeq)
|
||||
{
|
||||
registry = CommandRegistry.Instance;
|
||||
|
@ -437,8 +414,6 @@ namespace Bot
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
foreach (IProgram plugin in g_ZPrograms)
|
||||
{
|
||||
plugin.getTick(); // Trigger a tick event!!!
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue