How to get a variable from local controller when in multiplayer game.

Hi, all.
I want to get a variable from the local controller to refresh other controller’s variable.
But if I create a custom event with “Run On Server”, and give it a parameter of local controller, I can’t get the variable from the parameter.
I only can get this parameter from server controller.
Can anyone help me?




A HUD/umg element cannot call to the server. This is client side only.

You would want to use the umg to call an event on the player controller that will then call to the server.

Ie button is pressed cast to player controller run event choose team

Then on the player controller this does the logic and calls the server function

I made an example project for someone here:

I changed my project, now I can select team and attach the specified player controller to the specified character, but if I want to get the variables from the character in the umg on client, it always can’t get the player character.