[Ajuda] SetCar
#8

Quote:

new string[256];
new cmd[128], idx; //
new tmp[128]; //
cmd = strtok(cmdtext, idx);//

CMDetcar(playerid, params[]) {
if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, -1, "teste");
new plid, modeloid,cor1,cor2;

tmp = strtok(cmd, idx);
if(!strlen(tmp)){
SendClientMessage(playerid, vermelho, "[Info-Insano]: /setcar [PlayerID] [ModeloID] [Cor1] [Cor2]");
return 1;
}
plid = strval(tmp);
//================================================== ====================
tmp = strtok(cmd, idx);
if(!strlen(tmp)) {
SendClientMessage(playerid, vermelho, "[Info-Insano]: /setcar [PlayerID] [ModeloID] [Cor1] [Cor2]");
return 1;
}
modeloid = strval(tmp);
//================================================== ====================
tmp = strtok(cmd, idx);
if(!strlen(tmp)) {
SendClientMessage(playerid, vermelho, "[Info-Insano]: /setcar [PlayerID] [ModeloID] [Cor1] [Cor2]");
return 1;
}
cor1 = strval(tmp);
//================================================== ====================
tmp = strtok(cmd, idx);
if(!strlen(tmp)) {
SendClientMessage(playerid, vermelho, "[Info-Insano]: /setcar [PlayerID] [ModeloID] [Cor1] [Cor2]");
return 1;
}
cor2 = strval(tmp);
//================================================== ====================
if(!IsPlayerConnected(plid)){
SendClientMessage(playerid, vermelho, "[Info-Insano]: Jogador nгo estб conectado!");
return 1;
}
if(modeloid >= 400 && modeloid <= 611){
if(CriarVeiculoPlayer(playerid,plid,modeloid,cor1, cor2)){
SendClientMessage(playerid, verde, "[Info-Insano]: Veiculo Criado e Salvo com sucesso!");
new msg[256];
format(msg,256,"[Info-RedBull]: O Administrador %s Criou Um Veiculo Exclusivo Para Vocк!",PlayerNome(playerid));
SendClientMessage(plid, verde, msg);
}else{
SendClientMessage(playerid, verde, "[Info-Insano]: Erro ao criar o veiculo!");
}
return 1;
}else{
SendClientMessage(playerid, vermelho, "[Info-Insano]: Modelo ID Incorreto! (400-611)");
return 1;
}
}
return 0;
}

Inteiro ^ , e estб a include zcmd ...
Reply


Messages In This Thread
SETCAR , PRECISO DE AJUDA RAPIDO - by iD4N0N3_.x[X]x - 22.03.2014, 22:04
Re: SetCar - by DannielCooper - 22.03.2014, 23:35
Re: SetCar - by iD4N0N3_.x[X]x - 22.03.2014, 23:42
Re: SetCar - by DannielCooper - 22.03.2014, 23:51
Re: SetCar - by iD4N0N3_.x[X]x - 23.03.2014, 00:00
Re: SetCar - by DannielCooper - 23.03.2014, 00:14
Re: SetCar - by Couto - 23.03.2014, 00:37
Re: SetCar - by iD4N0N3_.x[X]x - 23.03.2014, 01:15

Forum Jump:


Users browsing this thread: 1 Guest(s)