-
Book Overview & Buying
-
Table Of Contents
Unreal Engine 4 Scripting with C++ Cookbook
By :
The IHttpRequest object from HTTP API will report HTTP download progress via a callback on a FHttpRequestProgressDelegate accessible via OnRequestProgress(). The signature of the function we can attach to the OnRequestProgress() delegate is as follows:
HandleRequestProgress( FHttpRequestPtr request, int32 sentBytes, int32 receivedBytes )
The three parameters of the function you may write include: the original IHttpRequest object, the bytes sent, and the bytes received so far. This function gets called back periodically until the IHttpRequest object completes, which is when the function you attach to OnProcessRequestComplete() gets called. You can use the values passed to your HandleRequestProgress function to advance a progress bar that you will create in UMG.
You will need an internet connection to use this recipe. We will be requesting a file from a public server. You can use a public server or your own private server for your HTTP request if...
Change the font size
Change margin width
Change background colour