private void Start()
    {
        m_currentScore = 0;
        // Initialize m_highScores to 0 if no file exists on Disk
        PlayerHighScores scores = m_highScoreTracker.LoadScores();

        if (scores == null)
        {
            for (int i = 0; i < 10; i++)
            {
                m_highScores.Add(0);
                //m_highScores[i] = 0;
            }
        }
        else
        {
            m_highScores = scores.HighScores;
        }

        if (m_player == null)
        {
            m_player = GameObject.FindGameObjectWithTag("Player");
        }

        // We cannot spawn until the initial countdown has finished. So the initial spawnTime needs to take this into account
        m_nextObstacleSpawnTime = Time.time + GameManager.S.m_countdownLength + m_timeBetweenSpawns;
        print("Setting Spawn time to: " + m_nextObstacleSpawnTime);

        // Set Coin spawn time to a ridiculously high number to ensure that all obstacles are spawned first;
        m_nextCoinFormationSpawnTime = Time.time + 1000f;

        // Set when we should increase difficulty
        m_increaseDifficultyTime = Time.time + m_difficultyInterval;
    }
    public void SaveScores(List <int> listToSave)
    {
        string filePath = Application.persistentDataPath + "\\HighScores.dat";

        // Save the data
        BinaryFormatter  bf   = new BinaryFormatter();
        FileStream       file = File.Create(filePath); // What if the file exists
        PlayerHighScores data = new PlayerHighScores(listToSave);

        bf.Serialize(file, data);
        file.Close();
    }
    // Use this for initialization
    void Start()
    {
        playerScores = m_highScoreTracker.LoadScores();

        if (playerScores != null)
        {
            for (int i = 0; i < playerScores.HighScores.Count; i++)
            {
                HighScores[i] = playerScores.HighScores[i];
                print(HighScores[i]);
            }
        }

        UpdateHighScoreList();
    }
    public PlayerHighScores LoadScores()
    {
        string filePath = Application.persistentDataPath + "\\HighScores.dat";

        // Make sure our file exists
        if (File.Exists(filePath))
        {
            BinaryFormatter  bf   = new BinaryFormatter();
            FileStream       file = File.Open(filePath, FileMode.Open);
            PlayerHighScores data = (PlayerHighScores)bf.Deserialize(file);
            file.Close();

            return(data);
        }
        else
        {
            return(null);
        }
    }