13.02.2011, 19:29
Okay, tell me what this prints:
Additionally what version of sscanf are you using? The plugin version or the old include version?
pawn Код:
stock L()
{
new Str[67], dModel, Float:VX, Float:VY, Float:VZ, Float:VA, vTotal;
mysql_query("SELECT * FROM `vehicles`");
mysql_store_result();
vTotal = mysql_num_rows();
if(vTotal > 0)
{
while(mysql_fetch_row(Str))
{
printf("Row: %s",str);
sscanf(Str, "p<|>iffff", dModel, VX, VY, VZ, VA);
printf("Model: %d | VX: %f | VY: %f | VZ: %f | VA: %f",dModel,VX,VY,VZ,VA);
new VID = CreateVehicle(dModel, VX, VY, VZ, VA, -1, -1, (30 * 60));
SetVehicleNumberPlate(VID,"ISS");
}
}
mysql_free_result();
printf("%i vehicle loaded", vTotal);
return 1;
}