How to get ping when playing on dedicated server?

I made a dedicated server following this tutorial: - YouTube
I, however, decided not to host it on aws anymore and proceeded to host it on my computer and forward the port needed. I got it running well.
Now, all I want is a way to get the ping value / latency (in ms) to display in a widget. How can i do this?

There is a GetPing() function in APlayerState to get Ping

2 Likes