14.06.2012, 19:47
Quote:
What is with vehicleid 0 ?
if (vehicleid>0) { should be: if(vehicleid != INVALID_VEHICLE_ID) |

INVALID_VEHICLE_ID is 65535, I think.
Vehicles ids start from 1, try make a command to teleport to vehicle with ID 1000 just having 5 vehicles in your server and checking if the typed id isn't the same as INVALID_VEHICLE_ID. For example:
pawn Код:
COMMAND:gotoveh(playerid, params[])
{
new veh_id;
if(sscanf(params,"d",veh_id)) return 1;
if(veh_id != INVALID_VEHICLE_ID)
{
//Teleport
} else { SendClientMessage(playerid,-1,"You won't get this message never"); }
return 1;
}
Good idea, and good job.
As they say, I think the looping form isn't the best.
Best regards!
