Get the current username
using Steamworks;
string username = SteamFriends.GetPersonaName();Last updated
To retrieve the current user name we use the GetPersonaName method from the SteamFriends class.
We also need to use the Steamworks namespace by adding using Steamworks; at the top of your class.
using Steamworks;
string username = SteamFriends.GetPersonaName();Last updated