Server Requests from Client

Introducing another alternative to the process of retrieving data from the client : ServerRequests

This method should appeal to those familiar with and enjoy the use of Promises. See link for more information. Cancelling a request is done via simple the Server’s Promise:cancel() method.

1 Like

What’s the point of using this over RemoteFunctions? Can’t I just wrap a Promise over InvokeClient using some other library?

That essentially all this is, just with a bit more overhead to make cancelling requests easier, and clients hook onto those requests with their own promise that will be cancelled if it is cancelled from the server. It also keeps a log of all the active requests to users.

And since it’s been wrapped, it just makes the user experience a bit less tedious for doing server requests. Instead of explicitly doing the wrap around the RemoteFunction with the promise, it’s done automatically internally. And, as I said, it has a few more extra nice freatures.

It would be far better if you included actual reasons use this in the post itself, rather than a link to the API (which IMO should be in the post itself) and some vague statements as to what it does.

If all this is is RemoteFunctions, “but with promises!”, then frankly I don’t know if this should even be on here.

As I said before, what’s stopping me from simply wrapping a possibly better Promise implementation (like this one) over a remote function? In my own eyes, this is almost exactly the same as that in terms of function.

I didn’t put much effort into the Roblox Forum post, you’re right. However, it is quite irritating that you’re taking such a strong stance on this when you haven’t even bothered to look at the link provided. The link you provided is literally the Promise that I am using the make these Server Requests…

You’ve put far more effort into criticizing something you haven’t put an effort into looking at when that effort could have gone towards simply reading the first sentence of the API.

I’m not sure what your problem is but I hope not to see you commenting on this thread again.

I’m not sure where you’re getting the “but with promises!” quote from, but it certainly wasn’t anything that I had said. This is indeed just a small, quality of life module that happens to utilize Promises.

i didnt know it was possible for something like this but still how would this work instead of
RM:InvokeServer(arg,etc)