Violet

Login

On this page

Read-only access to the login screen state. Useful from on_login_tick to drive world/channel/character selection automation.

Login Steps

StepMeaning
1World / channel select
2Character select
3New character — race / sub-job
4New character — name entry

Other values may appear during transitions.

Functions

core.login.get_step() -> number | nil

Returns the current login step, or nil if the player is not on the login screen (e.g. already in the field).

lua
function on_login_tick()
    local step = core.login.get_step()
    if step == 2 then
        -- character select is up
    end
end

core.login.get_char_count() -> number | nil

Returns the number of characters in the currently selected world's slot list. Only valid during step 2 (character select); returns nil otherwise.

lua
function on_login_tick()
    local count = core.login.get_char_count()
    if count and count == 0 then
        -- empty roster — auto-create flow can take over
    end
end