Tournaments (Unity)
FRVRSDK.Tournament covers timed competitive events with a shared starting payload and a shared leaderboard. Pairs naturally with end‑of‑match flow: call CreateOrPostScore after every run and the player is either creating a new tournament or extending their entry in the current one.
Check support first
Section titled “Check support first”Sandboxed / server‑less channels won’t support tournaments at all. Individual actions (create, invite, …) may be gated separately — check IsSupportedAPI before wiring a button.
Post a score
Section titled “Post a score”Create a tournament
Section titled “Create a tournament”Create does not take a score — it just creates the tournament. To post the player’s first score in the same flow, use CreateOrPostScore below.
payloadJson is free‑form JSON — every participant gets the same string, so use it to seed the run.
End‑of‑match helper: CreateOrPostScore
Section titled “End‑of‑match helper: CreateOrPostScore”This is the call you want from “you died, show a score screen”. If the player isn’t in a tournament, the native dialog offers to create one; if they are, their score is submitted. One call, right behaviour in both states. Note the argument order: endTime comes before score in the C# signature.
The result JSON deserializes into CreateOrPostScoreResult { string action; string tournamentId; }.
Read tournaments
Section titled “Read tournaments”Current tournament (the one the player is in, if any). TournamentInfo has id, created, startTime, endTime:
Player’s full tournament list:
Active tournaments surfaced by the host platform — these come back as PlatformTournament with richer fields (title, type, players, …):
Join / leave / invite
Section titled “Join / leave / invite”image is a base64 data URL — same shape as Social.Share.
Related
Section titled “Related”- Tournament concepts (payload, sort order, end time): Web SDK tournaments.