serenity icon indicating copy to clipboard operation
serenity copied to clipboard

Event for when all shards are ready

Open Milo123459 opened this issue 2 years ago • 4 comments

Wasn't sure how to implement this so I'm putting it here in an issue so perhaps someone else can pick it up or explain how to implement it.

Milo123459 avatar Apr 08 '22 10:04 Milo123459

Hi!

I have this implemented, here's the link below for reference.

https://github.com/Headline/discord-compiler-bot/blob/80a615b74ce1295e475bb60c791d29a924d9bf07/src/events.rs#L245-L261

Headline avatar Apr 20 '22 05:04 Headline

Do you think you could work on adding this event directly into serenity?

Milo123459 avatar Apr 20 '22 06:04 Milo123459

Do you think you could work on adding this event directly into serenity?

It's really up to the maintainers to decide if they'd want such an event. I'd implement it if green lit

Headline avatar Apr 21 '22 00:04 Headline

What would happen in the case that (with 2 shards)

Shard 0: Ready Shard 0: Disconnects Shard 1: Ready Shard 0: Ready (again)?

Or even if, after a while of running, a shard disconnects and reconnects, would this trigger the callback again?

GnomedDev avatar Jul 27 '22 00:07 GnomedDev