27.02.2014, 22:52
To delete all existing bikes with model-id 510, use this code.
It loops through all vehicle-id's, checks if each one has model-id 510, and if it matches, it will be deleted.
It loops through all vehicle-id's, checks if each one has model-id 510, and if it matches, it will be deleted.
pawn Код:
dcmd_removebike(playerid,params[])
{
#pragma unused params
for (new vid; vid < MAX_VEHICLES; vid++)
{
if (GetVehicleModel(vid) == 510)
DestroyVehicle(vid);
}
return 1;
}