コード例 #1
0
        public override void Run(BotMain bot, BotCommandController commandController, string[] rawTerms, string[] terms, string characterName, string channel, UserGeneratedCommand command)
        {
            string channelId = Utils.GetChannelIdFromInputs(rawTerms);

            string sendMessage = "Attempting to join channel: " + channelId;

            bot.JoinChannel(channelId);

            //send to character if there is no origin channel for this command
            if (!commandController.MessageCameFromChannel(channel))
            {
                bot.SendPrivateMessage(sendMessage, characterName);
            }
            else
            {
                bot.SendMessageInChannel(sendMessage, channel);
            }
        }