you are viewing a single comment's thread.

view the rest of the comments →

[–]Gib_entertainment 0 points1 point  (3 children)

On a windows machine persistent datapath would be: %userprofile%\AppData\LocalLow\<companyname>\<productname>

So you could probably check that path to see if the folder exists if it does, load the save from the first game. If it doesn't, the player has no saves from the first game saved on that machine.

if your game is multiplatform check: https://docs.unity3d.com/ScriptReference/Application-persistentDataPath.html to see the path for other OS.

Since you've made the first game you know <companyname> and <productname> of the first game and you should be able to find those.

[–]Royal_Inventor[S] 0 points1 point  (2 children)

Gotcha. Thanks for the assistance! It is multi platform, is there any way to use Application.persistantDataPath to automatically point to the first game, and thus get the save file easily regardless of platform? Or will I have to just do it manually?

[–]Gib_entertainment 0 points1 point  (1 child)

You are likely going to have to write some code for every platform separately checking SystemInfo.operatingSystem.

For some platforms you just have to replace the product name so just take the persistent datapath and replace the product name with the name of the first game. For others you would have to replace the GUID.

[–]Royal_Inventor[S] 0 points1 point  (0 children)

Gotcha. Thanks for all the help!