CooldownCheck constructor

CooldownCheck(
  1. Flags<CooldownType> type,
  2. Duration duration,
  3. {int tokensPer = 1,
  4. String? name}
)

Create a new CooldownCheck with a given type and duration.

tokensPer is optional and defaults to one, meaning a bucket can execute one before it is considered "on cooldown" for a given bucket.

Implementation

CooldownCheck(this.type, this.duration, {this.tokensPer = 1, String? name})
    : super(name ?? 'Cooldown Check on $type');