The idea is cool, but you should make an asynchronous implementation.
You are blocking the entire game thread with the http calls. this way is not very usable. Its specified in the cpp-httplib README that is a blocking library.
The idea is cool, but you should make an asynchronous implementation.
You are blocking the entire game thread with the http calls. this way is not very usable. Its specified in the cpp-httplib README that is a blocking library.
The problem has been found, an update will be available soon, please wait.
ryano_
you don't need to switch the library, but need a layer in between.
you can make something like:
create 2 queues (requests and responses) with data and a chai callback
create a worker thread that wakes up when requests not empty, process them and store the result in responses queue.
create a hook at server frame, if responses not empty, call the chai callback with the response data.
and the chai functions ('http_get '...) just store the data and callback in requests queue.
A comeback to Lua?
gsc.iprintln("hello boyz");
The problem has been found, an update will be available soon, please wait.