Exemple #1
0
 private void Events_ReceivedChatCommand(object sender, ReceivedPluginCommandEventArgs e)
 {
     if (Channels.Contains(e.Channel, StringComparer.OrdinalIgnoreCase) || string.IsNullOrWhiteSpace(e.Channel)) //Null or whitespace=  private command
     {
         ExecuteCommand(e.Character, e.Command, e.Arguments, e.Channel);
     }
 }
Exemple #2
0
        public void PassChatCommandToLoadedPlugins(object sender, ReceivedPluginCommandEventArgs e)
        {
            //There's no need to communicate this anymore, the plugins are handling the events directly by themselves.

            //string serializedCommand = JsonConvert.SerializeObject(e);
            //var body = Encoding.UTF8.GetBytes(serializedCommand);
            //_pubsubChannel.BasicPublish(exchange: "FChatSharpLib.Plugins.ToPlugins",
            //                     routingKey: "",
            //                     basicProperties: null,
            //                     body: body);
        }