public static void Ping(IGuildedClient client, MessageCreatedEvent messageCreated, string command, IList <string> arguments) { // Sends a message to channel where `ping`/`pong` command was used client.SendMessageAsync(messageCreated.ChannelId, // Generates a new message with content `Pong!` Message.Generate("Pong!") ); }
/// <summary> /// Sends a message to the specific channel. /// </summary> /// <param name="channel">Channel to send to</param> /// <param name="client">Client to send the message with</param> /// <param name="message">Message itself</param> public static async Task SendMessageAsync(this Channel channel, IGuildedClient client, NewMessage message) => await client.SendMessageAsync(channel.Id, message);