#1

PHP код:
    new playerserial[128];
    new 
gpcii gpci(playerid,playerserial,sizeof(playerserial));
    
pData[playerid][pGPCI] = gpcii;
            
        
format(querysizeof(query), "UPDATE `players` SET " );
        
        
format(tmpsizeof(tmp), "`GPCI`=%s, "pData[playerid][pGPCI] );
        
strcat(querytmp); 
not working because of %s. Any idea? i m trying to saving player gpci every last login so it keep updates every time player will quit games
Reply
#2

Missing '' in your query string. Change your format line to this...
pawn Код:
format(tmp, sizeof(tmp), "`GPCI`= '%s', ", pData[playerid][pGPCI] );
And it should work now.
Reply
#3



it looks like this here.
Reply
#4

gpci is a string
pawn Код:
new playerserial[50];
gpci(playerid,playerserial,sizeof(playerserial));

// pGPCI in enum should be a string too, pGPCI[50]

pData[playerid][pGPCI] = playerserial;

format(query, sizeof(query), "UPDATE `players` SET `GPCI` = '%s' WHERE something = something", playerserial, some array here);
Reply
#5

Well, I am using stract. any help?
Reply
#6

Still the same concept with or without strcat..
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)