Closed portaljumper007 closed 3 years ago
if we use socket io, will the games have to be "persistant" for this to work?
if we use socket io, will the games have to be "persistant" for this to work?
No, if I'm understanding you correctly 👯
The website should open a (for example) 30 secondly special new turn http request so that app.py can wait for the second, then trigger the new turn. This is an example for a 30 second turn timer.
well, with sockets there is no "requests" so the backend will have to run the timer or tell the client to return a "do nothing" if time runs out.
I am hoping sockets has some sort of could not contact client thing
well, with sockets there is no "requests" so the backend will have to run the timer or tell the client to return a "do nothing" if time runs out.
I am hoping sockets has some sort of could not contact client thing
Okay, if the backend needs to asynchronously time we may have to introduce threading and weird stuff... What's important in my opinion is that communication with the backend does NOT interrupt its runtime, right now if you send something to the backend it will interrupt what it's doing, that needs fixing (some sort of queue system.)
It works! Woop!
Requires socket.io and some sort of async timer system on the backend.