Hey everyone, I wanted to point out an issue that may come up with developing your games for Xbox. Xbox has a requirement that we identify the user by either their Xbox Display Name or Gamertag (we use Gamertag). This may (and very likely will be) different from the users Roblox username. The userId will be the same however.
We set the Player.Name property to the Gamertag. Gamertags can have characters that we do not allow for a Roblox username, which are left/right parenthesis and spaces. So anywhere you use the players name, you want to make sure that these characters will not break your game.
Another issue that may come up is if you display the users avatar image. Currently their are two ways to do this.
I would suggest you use the second url, where the userId is used. If you use the name, you will not get the correct image, as their gamertag is likely not the same as their Roblox user name.
Another issue that might come up is if you save any information with the users name as the key in a data store. On Xbox, a user can unlink their Roblox account from the Xbox Live account, then link the Xbox Live account to another Roblox account. If you save data associated with the name (gametag), this other Roblox account will get the data associated with that gamertag. We've seen cases where game passes were saved this way and users thought this was a "hack" to get a free game pass. Some Xbox users share one Xbox Live account among their family, unlinking and re-linking to their different Roblox accounts. So use the UserId to load the correct data for the correct user.
If you have any other questions or concerns about this, please let us know. Thanks everyone!