ZCMD GF -
Aleluja - 27.05.2011
Hi all , i started to edit GodFather and put all cmd's in ZCMD
And now i got problem.
When i write command that i put in ZCMD
Server write: Server; Unkown Command , but command work.. :S
Pls help
Here is command:
pawn Код:
CMD:cc(playerid, params[])
{
if(PlayerInfo[playerid][pAdmin] >= 1)
{
new cMsg[128], pName[MAX_PLAYER_NAME];
for(new c; c < 25; c++)
{
SendClientMessage(playerid, COLOR_RED, " ");
}
format(cMsg, sizeof(cMsg), "[Chat]: Admin %s je ocistio chat.", pName);
SendClientMessage(playerid, COLOR_LIGHTBLUE, cMsg);
SendClientMessage(playerid, COLOR_LIGHTBLUE, "www.sx-rp.info");
}
else SendClientMessage(playerid, COLOR_RED, "[ERROR]: Nisi Admin!");
return 1;
}
Re: ZCMD GF -
Aleluja - 27.05.2011
*******BUMP********
Respuesta: ZCMD GF -
admantis - 27.05.2011
pawn Код:
CMD:cc(playerid, params[])
{
if(PlayerInfo[playerid][pAdmin] >= 1)
{
new cMsg[128], pName[MAX_PLAYER_NAME];
for(new c; c < 25; c++)
{
SendClientMessage(playerid, COLOR_RED, " ");
}
format(cMsg, sizeof(cMsg), "[Chat]: Admin %s je ocistio chat.", pName);
SendClientMessage(playerid, COLOR_LIGHTBLUE, cMsg);
SendClientMessage(playerid, COLOR_LIGHTBLUE, "www.sx-rp.info"); return 1;
}
else SendClientMessage(playerid, COLOR_RED, "[ERROR]: Nisi Admin!");
return 1;
}
Always return 1 when your command ends!
Re: ZCMD GF -
Aleluja - 27.05.2011
Stil don't work.. i always put that..
Код:
CMD:cc(playerid, params[])
{
if(PlayerInfo[playerid][pAdmin] >= 1)
{
new cMsg[128], pName[MAX_PLAYER_NAME];
for(new c; c < 25; c++)
{
SendClientMessage(playerid, COLOR_RED, " ");
}
format(cMsg, sizeof(cMsg), "[Chat]: Admin %s je ocistio chat.", pName);
SendClientMessage(playerid, COLOR_LIGHTBLUE, cMsg);
SendClientMessage(playerid, COLOR_LIGHTBLUE, "www.sx-rp.info"); return 1;
}
else SendClientMessage(playerid, COLOR_RED, "[ERROR]: Nisi Admin!");
return 1;
}
//==============================================================================
public OnPlayerCommandReceived(playerid, cmdtext[])
{
return 1;
}
public OnPlayerCommandPerformed(playerid, cmdtext[], success)
{
new string[256];
new playermoney;
new sendername[MAX_PLAYER_NAME];
new giveplayer[MAX_PLAYER_NAME];
new playername[MAX_PLAYER_NAME];
new cmd[256];
new tmp[256];
new giveplayerid, moneys, idx;
cmd = strtok(cmdtext, idx);
That's have look in my gm.. :S
Re: ZCMD GF -
linuxthefish - 27.05.2011
pawn Код:
CMD:cc(playerid, params[])
{
if(PlayerInfo[playerid][pAdmin] >= 1)
{
new cMsg[128], pName[MAX_PLAYER_NAME];
for(new c; c < 25; c++)
{
SendClientMessage(playerid, COLOR_RED, " ");
}
format(cMsg, sizeof(cMsg), "[Chat]: Admin %s je ocistio chat.", pName);
SendClientMessage(playerid, COLOR_LIGHTBLUE, cMsg);
SendClientMessage(playerid, COLOR_LIGHTBLUE, "www.sx-rp.info");
return 1;
}
else SendClientMessage(playerid, COLOR_RED, "[ERROR]: Nisi Admin!");
return 1;
}
That should work, are you sure you are typing the same command? Can you post the whole of your OnPlayerCommandPerformed aswell please?
Re: ZCMD GF -
Biesmen - 27.05.2011
I had the same when I had around 20 ZCMD commands. I converted around 200 ZCMD commands to DCMD, and since that it was working again.
Re: ZCMD GF -
Aleluja - 27.05.2011
Stil don't work.. :S
I'm not typing same command's..
Pls help again?
Re: ZCMD GF -
linuxthefish - 27.05.2011
Are you returning 0 anywhere in OnPlayerCommandPerformed?
Re: ZCMD GF -
Biesmen - 27.05.2011
Edit: Double post, lol, please remove >.>
Re: ZCMD GF -
Aleluja - 27.05.2011
Quote:
Originally Posted by linuxthefish
Are you returning 0 anywhere in OnPlayerCommandPerformed?
|
Thank u !
PROBLEM SOLVED! :d