Jump to content
McKay Development

Frost Byte

Member
  • Posts

    18
  • Joined

  • Last visited

Reputation Activity

  1. Like
    Frost Byte reacted to Dr. McKay in How to go from Steam64 to Steam username (the name currently used on steam)   
    Your problem is that getPersonas expects an array as the first argument, and you aren't passing it an array. What you want to do is client.getPersonas([steamID], function(personas) { /* etc */ });
     
    Also in this case, the callback is essentially mandatory for you. getPersonas doesn't return anything. The data is only available inside the callback. In your case, you want something like this:
    client.getPersonas([steamID], function(personas) { var persona = personas[steamID.getSteamID64()]; var name = persona ? persona.player_name : ("[" + steamID.getSteamID64() + "]"); // the player's name is now available as name });
  2. Like
    Frost Byte got a reaction from Dr. McKay in How to go from Steam64 to Steam username (the name currently used on steam)   
    I found out myself!
     
    You already have the properties and methods from the steam handlers in your own steam-user library. So there I don't need a specific handler like 'friends' to send a message. I can just ask your steam-user object (in my case I called it client) and ask for the chatMessage method.
     
    Right? Well it works for me now 
     
    Yeah, it really works. And I managed to only use your node-steam-user library with all it's functions + your node-steamcommunity library!
×
×
  • Create New...