ACR_ServerCommunicator.ACR_ServerCommunicator.StartAccountAssociationCheck C# (CSharp) Method

StartAccountAssociationCheck() private method

Start a check to determine whether the player has associated a forum account in the database. The check runs asynchronously to avoid blocking the main thread.
private StartAccountAssociationCheck ( uint PlayerObject ) : void
PlayerObject uint Supplies the player object id.
return void
        private void StartAccountAssociationCheck(uint PlayerObject)
        {
            string AccountName = GetPCPlayerName(PlayerObject);

            WorldManager.SignalQueryThreadAction(delegate(IALFADatabase Database)
            {
                Database.ACR_SQLQuery(String.Format(
                    "SELECT `alfa_gsids`.`uid` FROM `alfa_gsids` WHERE `gsid` = '{0}'",
                    Database.ACR_SQLEncodeSpecialChars(AccountName)));

                //
                // If the player already has an account association, then there
                // is no work to be done.  Otherwise, request that the player
                // association GUI be opened.
                //

                if (Database.ACR_SQLFetch())
                    return;

                lock (WorldManager)
                {
                    WorldManager.EnqueueAccountAssociationToPlayer(PlayerObject,
                        WorldManager.Configuration.AccountAssociationSecret,
                        WorldManager.Configuration.AccountAssociationUrl);
                }
            });
        }
ACR_ServerCommunicator