19.04.2013, 20:03
i really need one here is cmds i use
pawn Код:
if(strcmp("/respawnmycars", cmdtext, true) == 0)
{
new query[250];
format(query,sizeof(query),"SELECT NULL FROM `pvehicles` WHERE OwnedBy = '%s'", PlayerName(playerid));
mysql_reconnect();
mysql_query(query);
mysql_store_result();
new rows = mysql_num_rows();
mysql_free_result();
new finished = 0;
if(rows > 0)
{
for(new i=0;i <sizeof(PVInfo);i++)
{
if(!IsVehicleOccupied(PVInfo[i][vpVehicleSpawned]))
{
if(!strcmp(PVInfo[i][vpOwnedBy], PlayerName(playerid)))
{
finished = 1;
SetVehicleToRespawn(PVInfo[i][vpVehicleSpawned]);
//ReloadVehicle(i);
}
}
}