Beispiel #1
0
 protected GamePlayer()
 {
     playerID = 0;
     username = "";
     email = "";
     experience = 0;
     session = "";
     SetLevel();
     update_instance = null;
 }
Beispiel #2
0
        /// <summary>
        /// Clears all data from variables stored in the player class
        /// after updating the experience on the server.
        /// </summary>
        public void ReleaseAccount()
        {
            if (update_instance == null)
            {
                update_instance = new Update();
            }

            SubmitExpChange();

            ClearData();
        }
Beispiel #3
0
 /// <summary>
 /// Creates a GamePlayer object with the given player's data.
 /// Creates a new Databasae Controller : Update instance to
 /// handle all the database operations needed throughout gameplay.
 /// </summary>
 /// <param name="p_id">The users unique ID</param>
 /// <param name="user">The users username</param>
 /// <param name="e_mail">The users email address</param>
 /// <param name="exp">The users current experience</param>
 /// <param name="sess">The session ID for this login</param>
 public void Initialize(int p_id, string user, string e_mail, int exp, string sess)
 {
     playerID = p_id;
     username = user;
     email = e_mail;
     experience = exp;
     session = sess;
     SetLevel();
     update_instance = new Update();
 }