Example #1
0
 /// <summary>
 /// The constructor for PlayerData, used in SaveGame().
 /// </summary>
 public PlayerData()
 {
     playerName  = "Sid";
     playerLevel = GameGlobals.GetPlayerLevel();
     currentXp   = GameGlobals.GetCurrentXp();
     xpLeft      = GameGlobals.GetXpLeft();
     maxes       = new int[3];
     maxes[0]    = GameGlobals.GetLiftFromLevel(0, playerLevel);
     maxes[1]    = GameGlobals.GetLiftFromLevel(1, playerLevel);
     maxes[2]    = GameGlobals.GetLiftFromLevel(2, playerLevel);
     for (int i = 0; i < 3; i++)
     {
         total += maxes[i];
     }
 }