常用方法
常用方法
常用方法
常用方法
/// <summary> /// Adds a role to a guild member /// </summary> /// <param name="guildId">ID of the guild</param> /// <param name="roleId">ID of the role</param> /// <param name="userId">ID of the guild member</param> public static void AddRoleToUser(this DiscordClient client, ulong guildId, ulong roleId, ulong userId) { client.AddRoleToUserAsync(guildId, roleId, userId).GetAwaiter().GetResult(); }