it does detect as a returning user when she opens it the second time
Force it to save. Maybe that's the problem. After calling PlayerPrefs.SetInt("IsReturningUser", 1);
, call PlayerPrefs.Save()
to save it.
If that does not help at-all, give the PlayerPrefs.GetInt
function a default value if the key does not exist like I did here. Just change PlayerPrefs.GetInt("IsReturningUser") == 1
to PlayerPrefs.GetInt("IsReturningUser", 0) == 1
.
Finally, if still not working, just use File.WriteAllBytes
and save the file to Application.persistentDataPath/yourFolderName
. You can find full example here.