Unity App42 SDK - storing score id in SQLite DB

259 Views Asked by At

I'm implementing a leaderboard service with App42 Unity SDK. The basic workflow is to save user's score first time, get the returned score id as described in tutorials,store it in the device local SQLite DB and then update the user score with that score id periodically.

The issue is that score id returned as a string which may contain SQLite invalid characters. "0QE9+50fILUfGERTTRIxLvmRRH8=" is one of such. How would you deal with the issue?

1

There are 1 best solutions below

0
Cenkisabi On

You can save your score ID in PlayerPrefs as string instead of SQLite

PlayerPrefs.SetString("ScoreID", score.scoreID);