Skip to content

OnPlayerDiscoveryRestore

The player’s game answered a restore - it applied it, or gave up.

For every kind a SetPlayerDiscovery or ForgetPlayerDiscovery carried, once the player’s game has answered. ok is false when the game could not do it - it cannot read that kind, it does not know this version of the game, the order could never be applied. The record kept what the mode set either way; the callback is for a mode that wants to know (a log line, a retry after the next spawn).

function OnPlayerDiscoveryRestore(pid, kind, ok)
-- ...
end
Parameter Type
pid number the player
kind string "places", "reading" or "ui"
ok boolean true when the game applied it, false when it gave up

nothing

function OnPlayerDiscoveryRestore(pid, kind, ok)
if not ok then Log(GetPlayerName(pid) .. "'s game could not restore the " .. kind) end
end

SetPlayerDiscovery · ForgetPlayerDiscovery · the Discovery - the map and the places a player found group of the index