21.06.2011, 11:41
Here you have:
pawn Код:
if (strcmp("/rcar", cmdtext, true, 10) == 0)
{
if(IsPlayerConnected(playerid))
{
new Name[MAX_PLAYER_NAME];
GetPlayerName(playerid,Name,sizeof(Name));
if(!strcmp(Name, "Tyler[DGZ]", true)) //Check the Player Name
{
new Float:X, Float:Y, Float:Z;
GetPlayerPos(playerid, X, Y, Z);
SetVehiclePos(1, X, Y, Z); //1 = vehicleid. || X = Position X || Y = Position Y || Z = Position Z.
PutPlayerInVehicle(playerid, 1, 0); //1 = vehicleid || 0 = State(0 = Driver)
}
else
{
SendClientMessage(playerid,-1,"You can't use this command!");
return 1;
}
}
return 1;
}