Clients can't access other players' controller [Advanced Sessions]

clients aren’t meant to communicate with other clients its a security risk and can also cause issues with gameplay. if client 1 was directly connected to client 2 then each would have a direct line into the others PC which bypasses all security by piggybacking on the game data. and from a gameplay perspective if you have events happening that are relative to more than one player but the server doesnt know about it then inconsistencies will occur and the whole system would break down. theres a reason all actions are taken by the server then replicated on clients.

For your case i would have client one request the server to get the data. when the server gets the username it can relay it back to client one if needed.

With the current way I have things set up, to be able to find a player’s Steam name, I have to have their PlayerController which I am attempting to get using the method below. The issue I’ve found with this is that only the server can use the “Get Controller” node and all other clients get a blank return value. Is there a better way to do this?

https://puu.sh/z64LJ/e87a50878c.png

Hey there, only the server can have access to all of the player controllers, the clients only have their own. For that you can use the Player State class to access common information.

No. But you can use the PlayerState instead.

It worked perfectly. Here is my new code.

https://puu.sh/z65Cu/d5ac6d64cd.png

Also thanks to Jin_VE