Table of Contents

Method WaitForEventAsync

Namespace
DSharpPlus
Assembly
DSharpPlus.dll

WaitForEventAsync<T>(Func<T, bool>, TimeSpan)

Waits for an event matching the specified condition.

public Task<EventWaiterResult<T>> WaitForEventAsync<T>(Func<T, bool> condition, TimeSpan timeout) where T : DiscordEventArgs

Parameters

condition Func<T, bool>

The condition an event needs to match.

timeout TimeSpan

A timeout for this event waiter.

Returns

Task<EventWaiterResult<T>>

Type Parameters

T