SA-MP Forums Archive
Save System Toys in SQL - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Save System Toys in SQL (/showthread.php?tid=565745)



Save System Toys in SQL - arititlez - 01.03.2015

I want to save information about Toy System because it can be stored in SQL format is highly recommended to me.

Quote:

for(new v = 0; v < MAX_PLAYERTOYS; v++)
{
MySQLUpdatePlayerInt(query, PlayerInfo[playerid][pSQLID], "ModelID", PlayerToyInfo[playerid][v][pModelID]);
MySQLUpdatePlayerInt(query, PlayerInfo[playerid][pSQLID], "Bone", PlayerToyInfo[playerid][v][pBone]);
MySQLUpdatePlayerFlo(query, PlayerInfo[playerid][pSQLID], "PosX", PlayerToyInfo[playerid][v][pPosX]);
MySQLUpdatePlayerFlo(query, PlayerInfo[playerid][pSQLID], "PosY", PlayerToyInfo[playerid][v][pPosY]);
MySQLUpdatePlayerFlo(query, PlayerInfo[playerid][pSQLID], "PosZ", PlayerToyInfo[playerid][v][pPosZ]);
MySQLUpdatePlayerFlo(query, PlayerInfo[playerid][pSQLID], "RotX", PlayerToyInfo[playerid][v][pRotX]);
MySQLUpdatePlayerFlo(query, PlayerInfo[playerid][pSQLID], "RotY", PlayerToyInfo[playerid][v][pRotY]);
MySQLUpdatePlayerFlo(query, PlayerInfo[playerid][pSQLID], "RotZ", PlayerToyInfo[playerid][v][pRotZ]);
MySQLUpdatePlayerFlo(query, PlayerInfo[playerid][pSQLID], "ScaleX", PlayerToyInfo[playerid][v][pScaleX]);
MySQLUpdatePlayerFlo(query, PlayerInfo[playerid][pSQLID], "ScaleY", PlayerToyInfo[playerid][v][pScaleY]);
MySQLUpdatePlayerFlo(query, PlayerInfo[playerid][pSQLID], "ScaleZ", PlayerToyInfo[playerid][v][pScaleZ]);
}




Re: Save System Toys in SQL - arititlez - 01.03.2015

help me please.