[Ajuda] 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: [Ajuda] Comando (
/showthread.php?tid=574498)
Comando -
Username1234 - 17.05.2015
Onde eu coloco um comando STRCMP?
Re: Comando -
CharCoast - 17.05.2015
Coloca em OnPlayerCommandText
Exemplo:
PHP код:
public OnPlayerCommandText(playerid, cmdtext[])
{
if(!strcmp(cmdtext, "/ajuda", true))
{
SendClientMessage(playerid, 0xFFFFFFFF, "SERVER: Este й comando /ajuda!");
return 1;
}
return 0;
}
Re: Comando -
Vegassilva - 17.05.2015
Coloque na callback OnPlayerCommandText ...
Re: Comando -
[BC]Vinny - 18.05.2015
Quote:
Originally Posted by CharCoast
Coloca em OnPlayerCommandText
Exemplo:
PHP код:
public OnPlayerCommandText(playerid, cmdtext[])
{
if(!strcmp(cmdtext, "/ajuda", true))
{
SendClientMessage(playerid, 0xFFFFFFFF, "SERVER: Este й comando /ajuda!");
return 1;
}
return 0;
}
|
porem й melhor vc usar processador de comandos
ZCMD й mais simples e facil de usar
https://sampforum.blast.hk/showthread.php?tid=493276