[AYUDA] Mysql login
#1

Hola este es el codigo.
pawn Код:
public OnPlayerLogin(playerid,password[]) // by Luk0r v1.0
{
    MySQLCheckConnection();
    new tmp2[256];
    new string2[64];
    new playername2[MAX_PLAYER_NAME];
    new playernamesplit[3][MAX_PLAYER_NAME];
    GetPlayerName(playerid, playername2, sizeof(playername2));
    split(playername2, playernamesplit, '_');
    MySQLFetchAcctSingle(PlayerInfo[playerid][pSQLID], "Password", PlayerInfo[playerid][pKey]);
    if(strcmp(PlayerInfo[playerid][pKey],password, true ) == 0 )
    {
        new Data[1024];
        new Field[256];
        new rcnt = 1;
        MySQLFetchAcctRecord(PlayerInfo[playerid][pSQLID], Data);
        samp_mysql_strtok(Field, "|", Data);
        while (samp_mysql_strtok(Field, "|", "")==1)
        {
            // The rcnt values here represent the order of the columns in the characters table, so don't mess with them
            // If you add a column to the table, just add a new line with a +1 rcnt to the block below
            // Start it at 3 to skip the first few records we don't need (id, player name, password)
            if (rcnt == 4) PlayerInfo[playerid][pLevel] = strval(Field[4]);
            if (rcnt == 5) PlayerInfo[playerid][pAdmin] = strval(Field[5]);
            if (rcnt == 6) PlayerInfo[playerid][pDonateRank] = strval(Field[6]);
            if (rcnt == 7) PlayerInfo[playerid][gPupgrade] = strval(Field[7]);
            if (rcnt == 8) PlayerInfo[playerid][pConnectTime] = strval(Field[8]);
            if (rcnt == 9) PlayerInfo[playerid][pReg] = strval(Field[9]);
            if (rcnt == 10) PlayerInfo[playerid][pSex] = strval(Field[10]);
            if (rcnt == 11) PlayerInfo[playerid][pAge] = strval(Field[11]);
            if (rcnt == 12) PlayerInfo[playerid][pOrigin] = strval(Field[12]);
            if (rcnt == 13) PlayerInfo[playerid][pCK] = strval(Field[13]);
            if (rcnt == 14) PlayerInfo[playerid][pMuted] = strval(Field[14]);
            if (rcnt == 15) PlayerInfo[playerid][pExp] = strval(Field[15]);
            if (rcnt == 16) PlayerInfo[playerid][pCash] = strval(Field[16]);
            if (rcnt == 17) PlayerInfo[playerid][pAccount] = strval(Field[17]);
            if (rcnt == 18) PlayerInfo[playerid][pCrimes] = strval(Field[18]);
            if (rcnt == 19) PlayerInfo[playerid][pKills] = strval(Field[19]);
            if (rcnt == 20) PlayerInfo[playerid][pDeaths] = strval(Field[20]);
            if (rcnt == 21) PlayerInfo[playerid][pArrested] = strval(Field[21]);
            if (rcnt == 22) PlayerInfo[playerid][pWantedDeaths] = strval(Field[22]);
            if (rcnt == 23) PlayerInfo[playerid][pPhoneBook] = strval(Field[23]);
            if (rcnt == 24) PlayerInfo[playerid][pLottoNr] = strval(Field[24]);
            if (rcnt == 25) PlayerInfo[playerid][pFishes] = strval(Field[25]);
            if (rcnt == 26) PlayerInfo[playerid][pBiggestFish] = strval(Field[26]);
            if (rcnt == 27) PlayerInfo[playerid][pJob] = strval(Field[27]);
            if (rcnt == 28) PlayerInfo[playerid][pPayCheck] = strval(Field[28]);
            if (rcnt == 29) PlayerInfo[playerid][pHeadValue] = strval(Field[29]);
            if (rcnt == 30) PlayerInfo[playerid][pJailed] = strval(Field[30]);
            if (rcnt == 31) PlayerInfo[playerid][pJailTime] = strval(Field[31]);
            if (rcnt == 32) PlayerInfo[playerid][pMats] = strval(Field[32]);
            if (rcnt == 33) PlayerInfo[playerid][pDrugs] = strval(Field[33]);
            if (rcnt == 34) PlayerInfo[playerid][pLeader] = strval(Field[34]);
            if (rcnt == 35) PlayerInfo[playerid][pMember] = strval(Field[35]);
            if (rcnt == 36) PlayerInfo[playerid][pFMember] = strval(Field[36]);
            if (rcnt == 37) PlayerInfo[playerid][pRank] = strval(Field[37]);
            if (rcnt == 38) PlayerInfo[playerid][pChar] = strval(Field[38]);
            if (rcnt == 39) PlayerInfo[playerid][pContractTime] = strval(Field[39]);
            if (rcnt == 40) PlayerInfo[playerid][pDetSkill] = strval(Field[40]);
            if (rcnt == 41) PlayerInfo[playerid][pSexSkill] = strval(Field[41]);
            if (rcnt == 42) PlayerInfo[playerid][pBoxSkill] = strval(Field[42]);
            if (rcnt == 43) PlayerInfo[playerid][pLawSkill] = strval(Field[43]);
            if (rcnt == 44) PlayerInfo[playerid][pMechSkill] = strval(Field[44]);
            if (rcnt == 45) PlayerInfo[playerid][pJackSkill] = strval(Field[45]);
            if (rcnt == 46) PlayerInfo[playerid][pCarSkill] = strval(Field[46]);
            if (rcnt == 47) PlayerInfo[playerid][pNewsSkill] = strval(Field[47]);
            if (rcnt == 48) PlayerInfo[playerid][pDrugsSkill] = strval(Field[48]);
            if (rcnt == 49) PlayerInfo[playerid][pCookSkill] = strval(Field[49]);
            if (rcnt == 50) PlayerInfo[playerid][pFishSkill] = strval(Field[50]);
            if (rcnt == 51) PlayerInfo[playerid][pHealth] = floatstr(Field[51]);
            if (rcnt == 52) PlayerInfo[playerid][pSHealth] = floatstr(Field[52]);
            if (rcnt == 53) PlayerInfo[playerid][pInt] = strval(Field[53]);
            if (rcnt == 54) PlayerInfo[playerid][pLocal] = strval(Field[54]);
            if (rcnt == 55) PlayerInfo[playerid][pTeam] = strval(Field[55]);
            if (rcnt == 56) PlayerInfo[playerid][pModel] = strval(Field[56]);
            if (rcnt == 57) PlayerInfo[playerid][pPnumber] = strval(Field[57]);
            if (rcnt == 58) PlayerInfo[playerid][pPhousekey] = strval(Field[58]);
            if (rcnt == 59) PlayerInfo[playerid][pPcarkey] = strval(field[59]);
            if (rcnt == 60) PlayerInfo[playerid][pPcarkey2] = strval(field[60]);
            if (rcnt == 61) PlayerInfo[playerid][pPcarkey3] = strval(field[61]);
            if (rcnt == 62) PlayerInfo[playerid][pGangKey] = strval(field[62]);
            if (rcnt == 63) PlayerInfo[playerid][pPbiskey] = strval(field[63]);
            if (rcnt == 64) PlayerInfo[playerid][pPos_x] = floatstr(Field[64]);
            if (rcnt == 65) PlayerInfo[playerid][pPos_y] = floatstr(Field[65]);
            if (rcnt == 66) PlayerInfo[playerid][pPos_z] = floatstr(Field[66]);
            if (rcnt == 67) PlayerInfo[playerid][pCarLic] = strval(Field[67]);
            if (rcnt == 68) PlayerInfo[playerid][pFlyLic] = strval(Field[68]);
            if (rcnt == 69) PlayerInfo[playerid][pBoatLic] = strval(Field[69]);
            if (rcnt == 70) PlayerInfo[playerid][pFishLic] = strval(Field[70]);
            if (rcnt == 71) PlayerInfo[playerid][pGunLic] = strval(Field[71]);
            if (rcnt == 72) PlayerInfo[playerid][pGun1] = strval(Field[72]);
            if (rcnt == 73) PlayerInfo[playerid][pGun2] = strval(Field[73]);
            if (rcnt == 74) PlayerInfo[playerid][pGun3] = strval(Field[74]);
            if (rcnt == 75) PlayerInfo[playerid][pGun4] = strval(Field[75]);
            if (rcnt == 76) PlayerInfo[playerid][pAmmo1] = strval(Field[76]);
            if (rcnt == 77) PlayerInfo[playerid][pAmmo2] = strval(Field[77]);
            if (rcnt == 78) PlayerInfo[playerid][pAmmo3] = strval(Field[78]);
            if (rcnt == 79) PlayerInfo[playerid][pAmmo4] = strval(Field[79]);
            if (rcnt == 80) PlayerInfo[playerid][pCarTime] = strval(Field[80]);
            if (rcnt == 81) PlayerInfo[playerid][pPayDay] = strval(Field[81]);
            if (rcnt == 82) PlayerInfo[playerid][pPayDayHad] = strval(Field[82]);
            if (rcnt == 83) PlayerInfo[playerid][pWatch] = strval(Field[83]);
            if (rcnt == 84) PlayerInfo[playerid][pCrashed] = strval(Field[84]);
            if (rcnt == 85) PlayerInfo[playerid][pWins] = strval(Field[85]);
            if (rcnt == 86) PlayerInfo[playerid][pLoses] = strval(Field[86]);
            if (rcnt == 87) PlayerInfo[playerid][pAlcoholPerk] = strval(Field[87]);
            if (rcnt == 88) PlayerInfo[playerid][pDrugPerk] = strval(Field[88]);
            if (rcnt == 89) PlayerInfo[playerid][pMiserPerk] = strval(Field[89]);
            if (rcnt == 90) PlayerInfo[playerid][pPainPerk] = strval(Field[90]);
            if (rcnt == 91) PlayerInfo[playerid][pTraderPerk] = strval(Field[91]);
            if (rcnt == 92) PlayerInfo[playerid][pTut] = strval(Field[92]);
            if (rcnt == 93) PlayerInfo[playerid][pMissionNr] = strval(Field[93]);
            if (rcnt == 94) PlayerInfo[playerid][pWarns] = strval(Field[94]);
            if (rcnt == 95) PlayerInfo[playerid][pVirWorld] = strval(Field[95]);
            if (rcnt == 96) PlayerInfo[playerid][pFuel] = strval(Field[96]);
            if (rcnt == 97) PlayerInfo[playerid][pMarried] = strval(Field[97]);
            if (rcnt == 98) PlayerInfo[playerid][pMarriedTo] = strval(Field[98]);
            if (rcnt == 99) PlayerInfo[playerid][pFishTool] = strval(field[99]);
            if (rcnt == 100) PlayerInfo[playerid][pInvWeapon] = strval(field[100]);
            if (rcnt == 101) PlayerInfo[playerid][pInvAmmo] = strval(field[101]);
            if (rcnt == 102) PlayerInfo[playerid][pLighter] = strval(field[102]);
            if (rcnt == 103) PlayerInfo[playerid][pCigarettes] = strval(field[103]);
            if (rcnt == 104) PlayerInfo[playerid][pRequestingBackup] = strval(field[104]);
            if (rcnt == 105) PlayerInfo[playerid][pRoadblock] = strval(field[105]);
            if (rcnt == 106) PlayerInfo[playerid][pMask] = strval(field[106]);
            if (rcnt == 107) PlayerInfo[playerid][pBomba] = strval(field[107]);
            if (rcnt == 108) PlayerInfo[playerid][pMaskuse] = strval(field[108]);
            if (rcnt == 109) PlayerInfo[playerid][pHideNumber] = strval(field[109]);
            if (rcnt == 110) PlayerInfo[playerid][pSpeaker] = strval(field[110]);
            if (rcnt == 111) PlayerInfo[playerid][pLocked] = strval(Field[111]);
            if (rcnt == 112) PlayerInfo[playerid][pGPS] = strval(field[112]);
            if (rcnt == 113) PlayerInfo[playerid][pCasco] = strval(field[113]);
            if (rcnt == 114) PlayerInfo[playerid][pLente] = strval(field[114]);
            if (rcnt == 115) PlayerInfo[playerid][pLlaveP1] = strval(field[115]);
            if (rcnt == 116) PlayerInfo[playerid][pLlaveP2] = strval(field[116]);
            if (rcnt == 117) PlayerInfo[playerid][pLlaveP3] = strval(field[117]);
            if (rcnt == 118) PlayerInfo[playerid][pPuntosL] = strval(field[118]);
            if (rcnt == 119) PlayerInfo[playerid][pRelojM] = strval(field[119]);
            if (rcnt == 120) PlayerInfo[playerid][pSueldo] = strval(field[120]);
            rcnt++;
        }
        samp_mysql_free_result();
    }
// sigue pero no tiene nada q ver con los errores lo que sigue
Код:
C:\Users\franco\Desktop\Files\Samp\sv sin mysql  in- progress\gamemodes\a.pwn(23289) : error 017: undefined symbol "field"
C:\Users\franco\Desktop\Files\Samp\sv sin mysql  in- progress\gamemodes\a.pwn(23289) : warning 215: expression has no effect
C:\Users\franco\Desktop\Files\Samp\sv sin mysql  in- progress\gamemodes\a.pwn(23289) : error 001: expected token: ";", but found "]"
C:\Users\franco\Desktop\Files\Samp\sv sin mysql  in- progress\gamemodes\a.pwn(23289) : error 029: invalid expression, assumed zero
C:\Users\franco\Desktop\Files\Samp\sv sin mysql  in- progress\gamemodes\a.pwn(23289) : fatal error 107: too many error messages on one line
Salu2!
Reply
#2

Proba de esta manera

pawn Код:
public OnPlayerLogin(playerid,password[]) // by Luk0r v1.0
{
    MySQLCheckConnection();
    new tmp2[256];
    new string2[64];
    new playername2[MAX_PLAYER_NAME];
    new playernamesplit[3][MAX_PLAYER_NAME];
    GetPlayerName(playerid, playername2, sizeof(playername2));
    split(playername2, playernamesplit, '_');
    MySQLFetchAcctSingle(PlayerInfo[playerid][pSQLID], "Password", PlayerInfo[playerid][pKey]);
    if(strcmp(PlayerInfo[playerid][pKey],password, true ) == 0 )
    {
        new Data[1024];
        new Field[256];
        new rcnt = 1;
        MySQLFetchAcctRecord(PlayerInfo[playerid][pSQLID], Data);
        samp_mysql_strtok(Field, "|", Data);
        while (samp_mysql_strtok(Field, "|", "")==1)
        {
            // The rcnt values here represent the order of the columns in the characters table, so don't mess with them
            // If you add a column to the table, just add a new line with a +1 rcnt to the block below
            // Start it at 3 to skip the first few records we don't need (id, player name, password)
            if (rcnt == 4) PlayerInfo[playerid][pLevel] = strval(Field[4]);
            if (rcnt == 5) PlayerInfo[playerid][pAdmin] = strval(Field[5]);
            if (rcnt == 6) PlayerInfo[playerid][pDonateRank] = strval(Field[6]);
            if (rcnt == 7) PlayerInfo[playerid][gPupgrade] = strval(Field[7]);
            if (rcnt == 8) PlayerInfo[playerid][pConnectTime] = strval(Field[8]);
            if (rcnt == 9) PlayerInfo[playerid][pReg] = strval(Field[9]);
            if (rcnt == 10) PlayerInfo[playerid][pSex] = strval(Field[10]);
            if (rcnt == 11) PlayerInfo[playerid][pAge] = strval(Field[11]);
            if (rcnt == 12) PlayerInfo[playerid][pOrigin] = strval(Field[12]);
            if (rcnt == 13) PlayerInfo[playerid][pCK] = strval(Field[13]);
            if (rcnt == 14) PlayerInfo[playerid][pMuted] = strval(Field[14]);
            if (rcnt == 15) PlayerInfo[playerid][pExp] = strval(Field[15]);
            if (rcnt == 16) PlayerInfo[playerid][pCash] = strval(Field[16]);
            if (rcnt == 17) PlayerInfo[playerid][pAccount] = strval(Field[17]);
            if (rcnt == 18) PlayerInfo[playerid][pCrimes] = strval(Field[18]);
            if (rcnt == 19) PlayerInfo[playerid][pKills] = strval(Field[19]);
            if (rcnt == 20) PlayerInfo[playerid][pDeaths] = strval(Field[20]);
            if (rcnt == 21) PlayerInfo[playerid][pArrested] = strval(Field[21]);
            if (rcnt == 22) PlayerInfo[playerid][pWantedDeaths] = strval(Field[22]);
            if (rcnt == 23) PlayerInfo[playerid][pPhoneBook] = strval(Field[23]);
            if (rcnt == 24) PlayerInfo[playerid][pLottoNr] = strval(Field[24]);
            if (rcnt == 25) PlayerInfo[playerid][pFishes] = strval(Field[25]);
            if (rcnt == 26) PlayerInfo[playerid][pBiggestFish] = strval(Field[26]);
            if (rcnt == 27) PlayerInfo[playerid][pJob] = strval(Field[27]);
            if (rcnt == 28) PlayerInfo[playerid][pPayCheck] = strval(Field[28]);
            if (rcnt == 29) PlayerInfo[playerid][pHeadValue] = strval(Field[29]);
            if (rcnt == 30) PlayerInfo[playerid][pJailed] = strval(Field[30]);
            if (rcnt == 31) PlayerInfo[playerid][pJailTime] = strval(Field[31]);
            if (rcnt == 32) PlayerInfo[playerid][pMats] = strval(Field[32]);
            if (rcnt == 33) PlayerInfo[playerid][pDrugs] = strval(Field[33]);
            if (rcnt == 34) PlayerInfo[playerid][pLeader] = strval(Field[34]);
            if (rcnt == 35) PlayerInfo[playerid][pMember] = strval(Field[35]);
            if (rcnt == 36) PlayerInfo[playerid][pFMember] = strval(Field[36]);
            if (rcnt == 37) PlayerInfo[playerid][pRank] = strval(Field[37]);
            if (rcnt == 38) PlayerInfo[playerid][pChar] = strval(Field[38]);
            if (rcnt == 39) PlayerInfo[playerid][pContractTime] = strval(Field[39]);
            if (rcnt == 40) PlayerInfo[playerid][pDetSkill] = strval(Field[40]);
            if (rcnt == 41) PlayerInfo[playerid][pSexSkill] = strval(Field[41]);
            if (rcnt == 42) PlayerInfo[playerid][pBoxSkill] = strval(Field[42]);
            if (rcnt == 43) PlayerInfo[playerid][pLawSkill] = strval(Field[43]);
            if (rcnt == 44) PlayerInfo[playerid][pMechSkill] = strval(Field[44]);
            if (rcnt == 45) PlayerInfo[playerid][pJackSkill] = strval(Field[45]);
            if (rcnt == 46) PlayerInfo[playerid][pCarSkill] = strval(Field[46]);
            if (rcnt == 47) PlayerInfo[playerid][pNewsSkill] = strval(Field[47]);
            if (rcnt == 48) PlayerInfo[playerid][pDrugsSkill] = strval(Field[48]);
            if (rcnt == 49) PlayerInfo[playerid][pCookSkill] = strval(Field[49]);
            if (rcnt == 50) PlayerInfo[playerid][pFishSkill] = strval(Field[50]);
            if (rcnt == 51) PlayerInfo[playerid][pHealth] = floatstr(Field[51]);
            if (rcnt == 52) PlayerInfo[playerid][pSHealth] = floatstr(Field[52]);
            if (rcnt == 53) PlayerInfo[playerid][pInt] = strval(Field[53]);
            if (rcnt == 54) PlayerInfo[playerid][pLocal] = strval(Field[54]);
            if (rcnt == 55) PlayerInfo[playerid][pTeam] = strval(Field[55]);
            if (rcnt == 56) PlayerInfo[playerid][pModel] = strval(Field[56]);
            if (rcnt == 57) PlayerInfo[playerid][pPnumber] = strval(Field[57]);
            if (rcnt == 58) PlayerInfo[playerid][pPhousekey] = strval(Field[58]);
            if (rcnt == 59) PlayerInfo[playerid][pPcarkey] = strval(Field[59]);
            if (rcnt == 60) PlayerInfo[playerid][pPcarkey2] = strval(Field[60]);
            if (rcnt == 61) PlayerInfo[playerid][pPcarkey3] = strval(Field[61]);
            if (rcnt == 62) PlayerInfo[playerid][pGangKey] = strval(Field[62]);
            if (rcnt == 63) PlayerInfo[playerid][pPbiskey] = strval(Field[63]);
            if (rcnt == 64) PlayerInfo[playerid][pPos_x] = floatstr(Field[64]);
            if (rcnt == 65) PlayerInfo[playerid][pPos_y] = floatstr(Field[65]);
            if (rcnt == 66) PlayerInfo[playerid][pPos_z] = floatstr(Field[66]);
            if (rcnt == 67) PlayerInfo[playerid][pCarLic] = strval(Field[67]);
            if (rcnt == 68) PlayerInfo[playerid][pFlyLic] = strval(Field[68]);
            if (rcnt == 69) PlayerInfo[playerid][pBoatLic] = strval(Field[69]);
            if (rcnt == 70) PlayerInfo[playerid][pFishLic] = strval(Field[70]);
            if (rcnt == 71) PlayerInfo[playerid][pGunLic] = strval(Field[71]);
            if (rcnt == 72) PlayerInfo[playerid][pGun1] = strval(Field[72]);
            if (rcnt == 73) PlayerInfo[playerid][pGun2] = strval(Field[73]);
            if (rcnt == 74) PlayerInfo[playerid][pGun3] = strval(Field[74]);
            if (rcnt == 75) PlayerInfo[playerid][pGun4] = strval(Field[75]);
            if (rcnt == 76) PlayerInfo[playerid][pAmmo1] = strval(Field[76]);
            if (rcnt == 77) PlayerInfo[playerid][pAmmo2] = strval(Field[77]);
            if (rcnt == 78) PlayerInfo[playerid][pAmmo3] = strval(Field[78]);
            if (rcnt == 79) PlayerInfo[playerid][pAmmo4] = strval(Field[79]);
            if (rcnt == 80) PlayerInfo[playerid][pCarTime] = strval(Field[80]);
            if (rcnt == 81) PlayerInfo[playerid][pPayDay] = strval(Field[81]);
            if (rcnt == 82) PlayerInfo[playerid][pPayDayHad] = strval(Field[82]);
            if (rcnt == 83) PlayerInfo[playerid][pWatch] = strval(Field[83]);
            if (rcnt == 84) PlayerInfo[playerid][pCrashed] = strval(Field[84]);
            if (rcnt == 85) PlayerInfo[playerid][pWins] = strval(Field[85]);
            if (rcnt == 86) PlayerInfo[playerid][pLoses] = strval(Field[86]);
            if (rcnt == 87) PlayerInfo[playerid][pAlcoholPerk] = strval(Field[87]);
            if (rcnt == 88) PlayerInfo[playerid][pDrugPerk] = strval(Field[88]);
            if (rcnt == 89) PlayerInfo[playerid][pMiserPerk] = strval(Field[89]);
            if (rcnt == 90) PlayerInfo[playerid][pPainPerk] = strval(Field[90]);
            if (rcnt == 91) PlayerInfo[playerid][pTraderPerk] = strval(Field[91]);
            if (rcnt == 92) PlayerInfo[playerid][pTut] = strval(Field[92]);
            if (rcnt == 93) PlayerInfo[playerid][pMissionNr] = strval(Field[93]);
            if (rcnt == 94) PlayerInfo[playerid][pWarns] = strval(Field[94]);
            if (rcnt == 95) PlayerInfo[playerid][pVirWorld] = strval(Field[95]);
            if (rcnt == 96) PlayerInfo[playerid][pFuel] = strval(Field[96]);
            if (rcnt == 97) PlayerInfo[playerid][pMarried] = strval(Field[97]);
            if (rcnt == 98) PlayerInfo[playerid][pMarriedTo] = strval(Field[98]);
            if (rcnt == 99) PlayerInfo[playerid][pFishTool] = strval(field[99]);
            if (rcnt == 100) PlayerInfo[playerid][pInvWeapon] = strval(Field[100]);
            if (rcnt == 101) PlayerInfo[playerid][pInvAmmo] = strval(Field[101]);
            if (rcnt == 102) PlayerInfo[playerid][pLighter] = strval(Field[102]);
            if (rcnt == 103) PlayerInfo[playerid][pCigarettes] = strval(Field[103]);
            if (rcnt == 104) PlayerInfo[playerid][pRequestingBackup] = strval(Field[104]);
            if (rcnt == 105) PlayerInfo[playerid][pRoadblock] = strval(Field[105]);
            if (rcnt == 106) PlayerInfo[playerid][pMask] = strval(Field[106]);
            if (rcnt == 107) PlayerInfo[playerid][pBomba] = strval(Field[107]);
            if (rcnt == 108) PlayerInfo[playerid][pMaskuse] = strval(Field[108]);
            if (rcnt == 109) PlayerInfo[playerid][pHideNumber] = strval(Field[109]);
            if (rcnt == 110) PlayerInfo[playerid][pSpeaker] = strval(Field[110]);
            if (rcnt == 111) PlayerInfo[playerid][pLocked] = strval(Field[111]);
            if (rcnt == 112) PlayerInfo[playerid][pGPS] = strval(Field[112]);
            if (rcnt == 113) PlayerInfo[playerid][pCasco] = strval(Field[113]);
            if (rcnt == 114) PlayerInfo[playerid][pLente] = strval(Field[114]);
            if (rcnt == 115) PlayerInfo[playerid][pLlaveP1] = strval(Field[115]);
            if (rcnt == 116) PlayerInfo[playerid][pLlaveP2] = strval(Field[116]);
            if (rcnt == 117) PlayerInfo[playerid][pLlaveP3] = strval(Field[117]);
            if (rcnt == 118) PlayerInfo[playerid][pPuntosL] = strval(Field[118]);
            if (rcnt == 119) PlayerInfo[playerid][pRelojM] = strval(Field[119]);
            if (rcnt == 120) PlayerInfo[playerid][pSueldo] = strval(Field[120]);
            rcnt++;
        }
        samp_mysql_free_result();
    }
// sigue pero no tiene nada q ver con los errores lo que sigue
Reply
#3

Me da los mismos errores :S
Reply
#4

El problema es que estas poniendo "field" y es "Field" con la F mayъscula.
Reply
#5

Debe quedar en otro lado field en minuscula porque los de esa parte les coloque a todos la f mayuscula xd
Reply
#6

Te recomiendo cambiar todo lo que tenes ahi para asignacion a las variables por sscanf, es mucho mas rapido y te vas a simplificar bastante.
Reply
#7

Muchisimas gracias! ya funciono!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)