07.01.2012, 22:27
(
Последний раз редактировалось Tanush123; 08.01.2012 в 15:18.
)
Ok i was changing up createbar then when i create in game and look at my DB, it doesnt INSERT anything
pawn Код:
CMD:createbar(playerid,params[])
{
if(PlayerData[playerid][AdminLevel] < 4) return 0;
new barid = GetBarid();
new bint = GetPlayerInterior(playerid);
new bworld = GetPlayerVirtualWorld(playerid);
if(barid == 0) return SCM(playerid,red,"ERROR: You have reached the maximum ID");
GetPlayerPos(playerid,X,Y,Z);
format(str,sizeof(str),"INSERT INTO Bars (ID,PosX,PosY,PosZ,Int,World) VALUES ('%d','%f','%f','%f','%i','%i')",GetBarid(),X,Y,Z,bint,bworld);
mysql_query(str);
UnloadBar();
SetTimerEx("ReloadBar",5000,0,"i",playerid);
format(str,sizeof(str),"You have created Bar ID: %d, all bars will load in 5 seconds",barid);
SCM(playerid,orange,str);
return 1;
}