Admin by Name! - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Admin by Name! (
/showthread.php?tid=524927)
Admin by Name! -
Akcent_Voltaj - 09.07.2014
hi this command dosent work no errors no warnings. I want players with name to work..i put this in command
PHP код:
new nick[24];
GetPlayerName(playerid,nick,24);
if(strcmp(nick, "Mircea", true) || strcmp(nick, "ARTIST", true))
{
SendClientMessage(playerid, COLOR_RED, " Nu esti Autorizat!");
return 1;
}
Re: Admin by Name! -
BroZeus - 09.07.2014
pawn Код:
if(strcmp(nick, "Mircea", true) || strcmp(nick, "ARTIST", true))
{
SendClientMessage(playerid, COLOR_RED, " Nu esti Autorizat!");
return 1;
}
this to this
pawn Код:
if(!strcmp(nick, "Mircea", true) || !strcmp(nick, "ARTIST", true))
{
SendClientMessage(playerid, COLOR_RED, " Nu esti Autorizat!");
return 1;
}
Re: Admin by Name! -
Akcent_Voltaj - 09.07.2014
PHP код:
dosent work.. says.. I tested and didn't work..
that im not authorized == SendClientMessage(playerid, COLOR_RED, " Nu esti Autorizat!");
Re: Admin by Name! -
BroZeus - 09.07.2014
pawn Код:
if(strcmp(nick, "Mircea", true) != 0 || strcmp(nick, "ARTIST", true) != 0)
{
SendClientMessage(playerid, COLOR_RED, " Nu esti Autorizat!");
return 1;
}
try this
Re: Admin by Name! -
Akcent_Voltaj - 09.07.2014
no work.
Re: Admin by Name! -
BroZeus - 09.07.2014
pawn Код:
if(!(strcmp(nick, "Mircea", true)==0 || strcmp(nick, "ARTIST", true) == 0))
Re: Admin by Name! -
Akcent_Voltaj - 09.07.2014
works. thanks. solved.