cmnds -
silentl747 - 11.06.2015
i can't use admin cmnds here it shows me unknown cmnd message
script
CMD:acmds(playerid)
{
if(pInfo[playerid][Adminlevel] < 1) return SCM(playerid, COLOR_ERROR, ""ERROR_MESSAGE"");
if(!pInfo[playerid][LoggedInAsAdmin]) return SCM(playerid,COLOR_ERROR,""ERROR_MESSAGE"");
HideAllServerTextDraws(playerid);
TextDrawShowForPlayer(playerid,acmds[0]);
TextDrawShowForPlayer(playerid,acmds[1]);
TextDrawShowForPlayer(playerid,acmds[2]);
TextDrawShowForPlayer(playerid,acmds[3]);
TextDrawShowForPlayer(playerid,acmds[8]);
viewing_acmds[playerid] =1;
page[1][playerid] =1;
return 1;
}
all admin cmnds are not working
Re: cmnds -
Devon007 - 11.06.2015
Try Replacing This
Код:
if(pInfo[playerid][Adminlevel] > 0)
Re: cmnds -
silentl747 - 11.06.2015
not working
Re: cmnds -
UltraScripter - 11.06.2015
if(pInfo[playerid][Adminlevel] <= 1) return SCM(playerid, COLOR_ERROR, ""ERROR_MESSAGE"");
Re: cmnds -
silentl747 - 11.06.2015
not working
Re: cmnds -
UltraScripter - 11.06.2015
Something wrong with ur textdraw
Re: cmnds -
Roberto80 - 11.06.2015
try:
if(pInfo[playerid][Adminlevel] = 0) return SCM(playerid, COLOR_ERROR, ""ERROR_MESSAGE"");
idk lol,
or use this:if(!IsPlayerAdmin) return SCM(playerid, COLOR_ERROR, "ERROR_MESSAGE");
Re: cmnds -
Konstantinos - 11.06.2015
If you get the default "SERVER: Unknown Command" message and the rest of the commands work, then it's probably a run time error.
Load crashdetect plugin and compile with -d3 flag.
https://github.com/Zeex/samp-plugin-...etect/releases
https://github.com/Zeex/samp-plugin-...ith-debug-info
After done those two things I mentioned above, re-compile, start the server and execute /acmds command.
If you get again the "SERVER: Unknown Command" message, post your server log.
Re: cmnds -
silentl747 - 11.06.2015
if(!pInfo[playerid][LoggedInAsAdmin]) return SCM(playerid,COLOR_ERROR,""ERROR_MESSAGE"");
i removed that line and its working
Re: cmnds -
SickAttack - 11.06.2015
Quote:
Originally Posted by silentl747
if(!pInfo[playerid][LoggedInAsAdmin]) return SCM(playerid,COLOR_ERROR,""ERROR_MESSAGE"");
i removed that line and its working
|
Then the function "SCM(...)" has something wrong with it, mind posting it?