Replies: 2 comments
-
Check out https://reactphp.org/event-loop/#addtimer - you can get the loop from |
Beta Was this translation helpful? Give feedback.
0 replies
-
Before you start using this Library you need to know how Event loops and Promises work. This is a fundamental requirement before you start. Without this knowledge, you will only suffer. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
The examples use
$discord->on($event)
to respond to something that happened in the channel.However, I'm reading game achievements from a database I want to:
That doesn't work because the closure never returns.
What I ended up doing is:
But:
Is there any way to hook into discord-php's event loop?
What I really need is something like
$discord->on('tick', 2, function() { ... })
.Is that possible?
Beta Was this translation helpful? Give feedback.
All reactions