SA-MP Forums Archive
[Ajuda] Ajuda, por favor. - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: Non-English (https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (https://sampforum.blast.hk/forumdisplay.php?fid=34)
+---- Thread: [Ajuda] Ajuda, por favor. (/showthread.php?tid=534378)



Ajuda, por favor. - LE4NDrO - 29.08.2014

Tenho esse comando
pawn Код:
CMD:rbola() return DestroyObject(BolaDeFutebol), BolaDeFutebol = CreateObject(1598, 1347.44,2149.91,10.3156, 0, 0, 0);
queria por para sу esse cargo poder utilizar :
pawn Код:
if(PlayerInfo[playerid][pFederacao] < 1) return SendClientMessage(playerid,ERRO,"ERRO: Voce nao tem permissao.");



Re: Ajuda, por favor. - ViniBorn - 29.08.2014

Й sу colocar dentro do comando.

Como existe mais de uma instruзгo, com as chaves fica mais fбcil de entender

pawn Код:
CMD:rbola(playerid)
{
    if(PlayerInfo[playerid][pFederacao] < 1) return SendClientMessage(playerid,ERRO,"ERRO: Voce nao tem permissao.");

    DestroyObject(BolaDeFutebol);
    BolaDeFutebol = CreateObject(1598, 1347.44,2149.91,10.3156, 0, 0, 0);
    return true;
}
Nгo sei exatamente o que o comando faz, mas se nгo for assim, basta inverter a linha do DestroyObject com a linha do CreateObject