19.07.2014, 13:47
Внезапно появилась проблема с плагином R5(https://sampforum.blast.hk/showthread.php?tid=56564). При апдейте аккаунтов появляется ошибка:
Собственно, втф?
Код:
[20:41:03] CMySQLHandler::Query(UPDATE `players1` SET `Level`=0,`Admin`=0,`Cash`=300,`Helper`=0,`Exp`=135,`Tut`=1,`Register`=0,`DonateRank`=0,`UpgradePoint`=0,`ConnectTime`=0,`Sex`=1,`Age`=26 WHERE `Name`='Hector_Ramirez') - An error has occured. (Error ID: 2014, Commands out of sync; you can't run this command now) [20:41:03] >> mysql_query( Connection handle: 1 )
Код:
new src[512],name[MAX_PLAYER_NAME],EscapeName[MAX_PLAYER_NAME]; GetPlayerName(playerid,name,sizeof(name)); mysql_real_escape_string(name, EscapeName); GetPlayerPos(playerid,PlayerInfo[playerid][pPos_x], PlayerInfo[playerid][pPos_y],PlayerInfo[playerid][pPos_z]); GetPlayerFacingAngle(playerid,PlayerInfo[playerid][pPos_f]); format(query,sizeof(query),"UPDATE `"PlayerTable"` SET "); format(src,sizeof(src),"`Level`=%d,",PlayerInfo[playerid][pLevel]); strcat(query,src,sizeof(query)); format(src,sizeof(src),"`Admin`=%d,",GetAdminLevel(playerid)); strcat(query,src,sizeof(query)); format(src,sizeof(src),"`Cash`=%d,",PlayerInfo[playerid][pCash]); strcat(query,src,sizeof(query)); format(src,sizeof(src),"`Helper`=%d,",PlayerInfo[playerid][pHelp]); strcat(query,src,sizeof(query)); format(src,sizeof(src),"`Exp`=%d,",PlayerInfo[playerid][pExp]); strcat(query,src,sizeof(query)); format(src,sizeof(src),"`Tut`=%d,",PlayerInfo[playerid][pTut]); strcat(query,src,sizeof(query)); format(src,sizeof(src),"`Register`=%d,",PlayerInfo[playerid][pReg]); strcat(query,src,sizeof(query)); format(src,sizeof(src),"`DonateRank`=%d,",PlayerInfo[playerid][pDonateRank]); strcat(query,src,sizeof(query)); format(src,sizeof(src),"`UpgradePoint`=%d,",PlayerInfo[playerid][gPupgrade]); strcat(query,src,sizeof(query)); format(src,sizeof(src),"`ConnectTime`=%d,",PlayerInfo[playerid][pConnectTime]); strcat(query,src,sizeof(query)); format(src,sizeof(src),"`Sex`=%d,",PlayerInfo[playerid][pSex]); strcat(query,src,sizeof(query)); format(src,sizeof(src),"`Age`=%d",PlayerInfo[playerid][pAge]); strcat(query,src,sizeof(query)); format(src,sizeof(src)," WHERE `Name`='%s'",EscapeName); strcat(query,src,sizeof(query)); mysql_query(query);