Custom Latent function for Actor Blueprint in C++

Check this post. cridia explained it pretty good.

I believe you have to use Latent Action Manager to achieve this.
Hope this helps!