09.12.2014, 22:52
pawn Код:
COMMAND:criarveiculo ( playerid, params[] )
{
return cmd_cv ( playerid, params );
}
COMMAND:cv ( playerid, params[] )
{
if(IsPlayerAdmin(playerid) )
{
new
STR[128],
Float:X,
Float:Y,
Float:Z,
Float:A,
Veiculo,
Modelo,
c1,
c2;
if(sscanf(params, "ddd", Modelo, c1, c2))
return SendClientMessage(playerid, -1, "| AVISO | Use:/cv [Modelo] [cor1] [cor2] ");
if( Modelo >= 400 && Modelo <= 611 )
{
GetPlayerPos(playerid, X, Y, Z);
GetPlayerFacingAngle(playerid, A);
Veiculo = AddStaticVehicleEx(Modelo, X, Y, Z, A, c1, c2, 30);
PutPlayerInVehicle(playerid, Veiculo, 0);
format(STR, sizeof (STR), "| INFO | Administrador(a) Vocк criou o Veiculo %d com Sucesso.", Modelo );
SendClientMessage(playerid, -1, STR);
}else{
SendClientMessage(playerid, -1, "| AVISO | ID Invбlido use [400 a 611]");
}
}else{
SendClientMessage(playerid, -1, "| AVISO | Vocк nгo tem Permissгo.");
}
return 1;
}