public void UserInitialize(CoreList CoreList) { ServerQueryConnection = (ServerQueryConnection.ServerQueryConnection)CoreList[typeof(ServerQueryConnection.ServerQueryConnection).Name]; //TODO: Add permission list from ts3 somehow //var PermissionsList = ServerQueryConnection.QueryRunner.GetPermissionList().ToList(); }
public void UserInitialize(CoreList AddonInjections) { this.ServerQueryConnection = AddonInjections[typeof(ServerQueryConnection.ServerQueryConnection).Name] as ServerQueryConnection.ServerQueryConnection; this.UserManager = AddonInjections[typeof(UserManager.UserManager).Name] as UserManager.UserManager; this.ServerQueryConnection.BotCommandAttempt += onBotCommand; ModelCustomizer.AddModelCustomization(Hooks.ModelCustomizer.OnModelCreating); }
public void UserInitialize(CoreList AddonInjections) { this.ServerQueryConnection = AddonInjections[typeof(ServerQueryConnection.ServerQueryConnection).Name] as ServerQueryConnection.ServerQueryConnection; this.UserManager = AddonInjections[typeof(UserManager.UserManager).Name] as UserManager.UserManager; this.ServerQueryConnection.QueryRunner.Notifications.ClientMessageReceived += Notifications_ClientMessageReceived; ModelCustomizer.AddModelCustomization(Hooks.ModelCustomizer.OnModelCreating); //logger.Info("I have been initialized yo!"); }
public void UserInitialize(CoreList AddonInjections) { this.Name = this.GetType().Name; ModelCustomizer.AddModelCustomization(Hooks.ModelCustomizer.OnModelCreating); this.ServerQueryConnection = AddonInjections[typeof(ServerQueryConnection.ServerQueryConnection).Name] as ServerQueryConnection.ServerQueryConnection; this.ServerQueryAddon = AddonInjections[typeof(ServerQueryShell.ServerQueryShell).Name] as ServerQueryShell.ServerQueryShell; // Native serverquery events are in queryRunner object. Uncomment if you want to use them. this.ServerQueryConnection.BotCommandAttempt += ServerQueryConnection_BotCommandReceived; this.ServerQueryConnection.QueryRunner.Notifications.ClientMoved += Notifications_ClientMoved; //logger.Debug("TestAddon initialized!"); }
public void UserInitialize(CoreList CoreList) { // Core Initialization ServerQueryConnection = (ServerQueryConnection.ServerQueryConnection)CoreList["ServerQueryConnection"]; // Addon Initialization // Just give us _all_ the cores (for now) so we can share them with the addons that need them this.CoreList = CoreList; // We can't initialize addons until the core addons have been initialized InitializeAddons(); GetSchemas(); ServerQueryConnection.BotCommandAttempt += onBotCommandAttempt; }
public CoreManager(ServerQueryConnection.Models.Subscribers Subscriber) { this.Subscriber = Subscriber; CoreList = new List <Base.ICore>(); CoreList.Add(ServerQueryConnection = new ServerQueryConnection.ServerQueryConnection(this.Subscriber)); CoreList.Add(new UserManager.UserManager(this.Subscriber)); //CoreList.Add(new Test.TestCore(this.Subscriber)); CoreList.Add(new InputOwner.InputOwnerAddon(this.Subscriber)); CoreList.Add(new ServerQueryShell.ServerQueryShell(this.Subscriber)); CoreList.Add(new PermissionManager.PermissionManager(this.Subscriber)); CoreList.Add(new ChannelManager.ChannelManager(this.Subscriber)); CoreList.Add(new AddonManager.AddonManager(this.Subscriber)); InitializeCores(); GetSchemas(); ServerQueryConnection.BotCommandAttempt += onBotCommandAttempt; }