Saving car information
#19

Код:
stock SaveVehicleToDatabase(vehicleid)
{
	new ModelID, Color1, Color2;
	new Float:PositionX, Float:PositionY, Float:PositionZ, Float:AngleZ;
	ModelID = GetVehicleModel(vehicleid);
	GetVehiclePos(vehicleid, PositionX, PositionY, PositionZ);
	GetVehicleZAngle(vehicleid, AngleZ);
	GetVehicleColor(vehicleid, Color1, Color2);

    format(Query, sizeof(Query), "INSERT INTO `Vehicles` (ModelID, PositionX, PositionY, PositionZ, AngleZ, Color1, Color2) VALUES(%d, %f, %f, %f, %f, %d, %d)", ModelID, PositionX, PositionY, PositionZ, AngleZ, Color1, Color2);
	mysql_query(Query);
	return 1;
}
Reply


Messages In This Thread
Saving car information - by Typhome - 16.11.2010, 17:38
Re: Saving car information - by JaTochNietDan - 16.11.2010, 18:31
Re: Saving car information - by Grim_ - 16.11.2010, 18:37
Re: Saving car information - by Typhome - 16.11.2010, 18:55
Re: Saving car information - by Grim_ - 16.11.2010, 18:59
Re: Saving car information - by JaTochNietDan - 16.11.2010, 19:00
Re: Saving car information - by Typhome - 16.11.2010, 19:39
Re: Saving car information - by JaTochNietDan - 16.11.2010, 20:40
Re: Saving car information - by Typhome - 16.11.2010, 21:25
Re: Saving car information - by JaTochNietDan - 16.11.2010, 21:50
Re: Saving car information - by Typhome - 17.11.2010, 15:22
Re: Saving car information - by Typhome - 18.11.2010, 22:45
Re: Saving car information - by NewbBeginner - 18.11.2010, 22:46
Re: Saving car information - by Scenario - 18.11.2010, 22:51
Re: Saving car information - by JaTochNietDan - 18.11.2010, 23:23
Re: Saving car information - by Scenario - 19.11.2010, 01:15
Re: Saving car information - by Typhome - 20.11.2010, 20:02
Re: Saving car information - by Typhome - 21.11.2010, 10:21
Re: Saving car information - by NewbBeginner - 21.11.2010, 10:56
Re: Saving car information - by Typhome - 21.11.2010, 12:18

Forum Jump:


Users browsing this thread: 1 Guest(s)