SA-MP Forums Archive
[Pedido] Bloquear os comando - 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: [Pedido] Bloquear os comando (/showthread.php?tid=467346)



Bloquear os comando - powerths - 02.10.2013

Tem algum geito de bloquear todos os comando de escrever, Й que tenho um sistema de presos.


Re: Bloquear os comando - TheKoDaK - 02.10.2013

Faзa uma Verificaзгo se o player estб preso.
pawn Код:
public OnPlayerCommandText(playerid, cmdtext);
{
    if(VariavelPreso == 1) return SendClientMenssage(playerid, -1, Vocк estб preso !);

    //Todos Comandos a Baixo !
    return 0;
}



Re: Bloquear os comando - smiiir - 02.10.2013

pawn Код:
new bool:BloquearPreso [ MAX_PLAYERS ] ;

COMMAND:oi ( playerid ) {

    if ( BloquearPreso [ playerid ] == true )
        return SendClientMessage ( playerid, -1, "You ta preso ksksks" ) ;

    return true ;
}
Coloca a variбvel BloquearPreso quando ele for preso

Exemplo:

pawn Код:
COMMAND:prender ( playerid ) {

    BloquearPreso [ playerid ] = true ;
    return true ;
}



Re: Bloquear os comando - powerths - 02.10.2013

Viw lek

botei isso if(dini_Int(file, "Preso") == 1){ nos comando quando player digitar.