IneedHelp
IneedHelp

Reputation: 1758

The Discord.net UserUpdated event doesn't trigger

Using Discord.Net 1.0.1

I would like to use the UserUpdated event to detect when users change their status, but it seems that this even doesn't trigger regardless of what changes the user makes (like changing status, nickname, avatar, etc.)

Sample code:

        this._client = new DiscordSocketClient(config: config);
        this._client.UserUpdated += this.Client_OnUserUpdated;

        private Task Client_OnUserUpdated(SocketUser arg1, SocketUser arg2)
    {
        Console.WriteLine(value: "Client_OnUserUpdated");
        return Task.CompletedTask;
    }

How can I make the event trigger when users change their properties?

Upvotes: 1

Views: 1977

Answers (1)

MX D
MX D

Reputation: 2485

By the sounds of it you are not looking for the OnUserUpdated which applies to the user (your bot).

Instead you would want GuildMemberUpdated which happens whenever a member of a guild is updated.

Upvotes: 5

Related Questions