M MY Multiplayer: Wiki
Side
Kind

getPlayerIdentifiers

Server

Lists all of the player's identifiers, each as type:value, for example steam:110000112345678 and discord:80351110224678912.

table|false getPlayerIdentifiers(player player)

Parameters

NameTypeDescription
playerplayerThe player.

Returns

A table of the identifiers, or false if the player has no entity on the server.

Example

addEventHandler("onPlayerJoin", root, function()
    for _, identifier in ipairs(getPlayerIdentifiers(source)) do
        outputServerLog(getPlayerName(source) .. ": " .. identifier)
    end
end)
NoteThe discord one comes from the player's Discord app and is not verified. The steam one is only verified when the server has a steam_api_key.

See also