Auto Increament (Player ID)
#3

Well, here it is.
pawn Код:
// Master Account Information
enum pInfo
{
    pID,
    Password,
    Admin,
}
new PlayerInfo[MAX_PLAYERS][pInfo];

// Character Information
enum cInfo
{
    mID,
}
new Character[MAX_CHARACTERS][cInfo];


// Under OnDialogResponse
case DIALOG_REGISTER:
        {
            if (!response) return Kick(playerid);
            if(response)
            {
                if(!strlen(inputtext)) return ShowPlayerDialog(playerid, DIALOG_REGISTER, DIALOG_STYLE_INPUT, "Register","You haven't entered anything. Please enter a password to Proceed.","Register","Quit");
                PlayerInfo[playerid][Password] = udb_hash(inputtext);
                SavePlayer(playerid);
               
            }
        }
I'm wondering, how to Link the Master Account with the Character. In MySQL, you simple can do:
mysql_function_query(connectionHandle, "SELECT `username` FROM `playerCharacters` WHERE `masteraccountID` = 1291", true, "loadAccounts", "d", playerid);
Reply


Messages In This Thread
Auto Increament (Player ID) - by JonathanW - 18.11.2014, 06:48
Re: Auto Increament (Player ID) - by Dairyll - 18.11.2014, 06:57
Re: Auto Increament (Player ID) - by JonathanW - 18.11.2014, 07:07
Re: Auto Increament (Player ID) - by Dairyll - 18.11.2014, 08:08
Re: Auto Increament (Player ID) - by JonathanW - 18.11.2014, 09:01
Re: Auto Increament (Player ID) - by Dairyll - 18.11.2014, 14:42
Re: Auto Increament (Player ID) - by JonathanW - 18.11.2014, 14:47

Forum Jump:


Users browsing this thread: 1 Guest(s)