Extra Vision
#1

pawn Код:
format(save, sizeof(save), "UPDATE Accounts SET W1 = %d, A1 = %d, W2 = %d, A2 = %d, W3 = %d, A3 = %d, W4 = %d, A4 = %d, W5 = %d, A5 = %d, W6 = %d, A6 = %d WHERE Username = '%s'",

        weapons[0][0],
        weapons[0][1],
        weapons[1][0],
        weapons[1][1],
        weapons[2][0],
        weapons[2][1],
        weapons[3][0],
        weapons[3][1],
        weapons[4][0],
        weapons[4][1],
        weapons[5][0],
        weapons[5][1],
        weapons[6][0],
        weapons[6][1],
        pName(playerid));
       
    mysql_query(save);
   
    format(save, sizeof(save), "UPDATE Accounts SET W7 = %d, A7 = %d, W8 = %d, A8 = %d, W9 = %d, A9 = %d, W10 = %d, A10 = %d, W11 = %d, A11 = %d, W12 = %d, A12 = %d, W13 = %d, A13 = %d WHERE Username = '%s'",
   
        weapons[7][0],
        weapons[7][1],
        weapons[8][0],
        weapons[8][1],
        weapons[9][0],
        weapons[9][1],
        weapons[10][0],
        weapons[10][1],
        weapons[11][0],
        weapons[11][1],
        weapons[12][0],
        weapons[12][1],
        pName(playerid));
       
    mysql_query(save);
I have these codes, and now in the debug it's stating
Код:
Username = ''
I can't figure out why the username isn't showing up for this lines, It shows for the other 5 saving lines I have, and they all look the same. So I just need some extra eyes, maybe im just missing some stupid thing, thanks in advance.
Reply
#2

Show the pName function.

Also re-check the way you're formatting. I already spotted one mistake.
Reply
#3

The issue is that you're specifying too many/too little modifiers in the string and you don't have enough parameters at the end to fill them up.

First format has 13 modifiers in the string and has 15 parameters, which means you have 2 too many parameters.
Second format has 15 modifiers in the string and 13 parameters, which means you don't have enough parameters!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)