User Tools

Site Tools


docs:api:getratingsdata

GetRatingsData

public static IEnumerator GetRatingsData(SupabasePreset supabasePreset, string ratingsTable, System.Action<string[][]> onComplete)

Function:

  • Fetches the ratings table specified on the supabase preset, and returns each row from the table.
  • data is returned as a multi-dimensional array: data[x][y]
    • where x is the row, from top to bottom
    • and y is the columns, from left to right

Requires a WebGLCallbackHandler

Example:

private void Start()
{
    // Get total plays from ratings table
    StartCoroutine(LivelyWebGL.Supabase.Tables.Ratings.GetRatingsData(supabasePreset, ratingsTable, (data) =>
    {
        foreach (string[] row in data)
        {
             Debug.Log(string.Join(",", row));
        }
    }));
}

docs/api/getratingsdata.txt · Last modified: by admin

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki