コード例 #1
0
 public static bool FileExists(string username)
 {
     if (FolderSystem.FileExists(Folder + username + ".xml"))
     {
         return(true);
     }
     return(false);
 }
コード例 #2
0
        public static bool VerifyAccount(string username, string password)
        {
            if (FolderSystem.FileExists(Folder + username + ".xml"))
            {
                Account player = new Account();
                player = Serialization.Deserialize <Account>(Folder + username + ".xml", player.GetType());

                if (player.Password == Encryption.Encrypt(password))
                {
                    return(true);
                }
            }
            return(false);
        }