Ejemplo n.º 1
0
    public static LevelStats Load(uint levelID)
    {
        string path = SaveSlot.GetCurrentSlotPath() + "/Levels/";

        if (!File.Exists(path + "Level " + levelID))
        {
            return(null);
        }

        LevelStats stats = new LevelStats();

        stats.Reset();

        StreamReader stream = new StreamReader(path + "Level " + levelID);

        stats.LoadLevelInfo(stream);
        stats.LoadLevelGlobalStats(stream);
        stats.LoadLevelTracking(stream);

        return(stats);
    }