OnPlayerLogin||doc136860

September 20, 2022

Format

local event = Event:GetEvent("OnPlayerLogin")

Describe

Launch this event after the player logs in. The event will be triggered on the client only when the main player logs in.

Callback function parameters

Type name introduce
Entity entity Login player's entity

Code example

local event = Event:GetEvent("OnPlayerLogin")
event:Bind(function(entity)
    print("OnPlayerLogin", entity)
end)