In this section, we will be creating two scripts for saving and loading the high score from our local machine. The first script will be the
UsersData script, which will contain all the functions to save and load the score to our local machine by using the
PlayerPrefs class. Then, we will create the
LocalHiScore script, which will contain the function to sort user scores and check for the final score submission. Finally, we will go back to the
HiScore script to create a
LocalHiscore object to save and load high scores locally.
Before we start, we need to know the basic parameters we need to include in the high-score table. We will need the order number, username, and the user score, as ...