OnPlayerSteamAuth: Difference between revisions

From Onset Developer Wiki
Created page with "{{Info|Event|Server & Client|1.0}} {{FuncDescription|Called when a player was authenticated by Steam. Once this event was called you can use GetPlayerSteamId to get the p..."
 
Chloe (talk | contribs)
m Added a note and changed it to player events tag.
Line 2: Line 2:


{{FuncDescription|Called when a player was authenticated by Steam. Once this event was called you can use [[GetPlayerSteamId]] to get the players SteamId.
{{FuncDescription|Called when a player was authenticated by Steam. Once this event was called you can use [[GetPlayerSteamId]] to get the players SteamId.
Steam identity authentication is mandatory. If it fails the player will be kicked.}}
Steam identity authentication is mandatory. If it fails the player will be kicked.
 
It's noteworthy that a player is able to spawn prior to being authenticated.}}


{{FuncSyntax|OnPlayerSteamAuth(player)}}
{{FuncSyntax|OnPlayerSteamAuth(player)}}
Line 18: Line 20:


{{RelatedFunctions}}
{{RelatedFunctions}}
{{ServerEvents}}
{{PlayerEvents}}

Revision as of 07:46, 16 January 2020

OnPlayerSteamAuth

Type: Event
Context: Server & Client
Introduced: v1.0

Description

Called when a player was authenticated by Steam. Once this event was called you can use GetPlayerSteamId to get the players SteamId. Steam identity authentication is mandatory. If it fails the player will be kicked.

It's noteworthy that a player is able to spawn prior to being authenticated.

Syntax

OnPlayerSteamAuth(player)

Parameters

  • player
    The player who was verified.

Example

function OnPlayerSteamAuth(player)
    AddPlayerChat(player, "Your SteamId: "..GetPlayerSteamId(player))
end
AddEvent("OnPlayerSteamAuth", OnPlayerSteamAuth)

See also