10.03.2013, 21:20
There is a Tutorial on this which I'll add after but as a quick example.
Firstly in random code and I'll add again one of your after.
Would be in ZCMD:
Your Code:
ZCMD:
// Your command doesn't use paramters
Tutorial: https://sampforum.blast.hk/showthread.php?tid=231496
Okay edits are done I included an example of your code as if your like my ZCMD will just come to you.
Firstly in random code and I'll add again one of your after.
pawn Код:
if(if(!strcmp(cmdtext, "/test", true))
{
return SendClientMessage(playerid, -1, "Hello World!");
}
pawn Код:
CMD:test(playerid) //You do see some with Paramaterss but my command doesn't have any.
{
SendClientMessage(playerid, -1, "Hello World!");
return 1;
}
pawn Код:
if(!strcmp(cmdtext, "/disguise", true))//dialog which tells u about the spy class disguises
{
if(gClass[playerid] == SPY)
{
ShowPlayerDialog(playerid, 88, DIALOG_STYLE_MSGBOX, "{6EF83C}Spy - Disguise Kit:", "/England\n/Soviet Union\n/Taliban\n/United States\n/Australian Armada", "Disguise ","Exit");//Replace the team1,2,3 to your game teams name and colors, by /team1 or /team2 or / team3 the player gets disguise to enemy soldier but don't changes its team
return 1;
}
// Your command doesn't use paramters
pawn Код:
CMD:disguise(playerid) //dialog which tells u about the spy class disguises
{
if(gClass[playerid] == SPY)
{
ShowPlayerDialog(playerid, 88, DIALOG_STYLE_MSGBOX, "{6EF83C}Spy - Disguise Kit:", "/England\n/Soviet Union\n/Taliban\n/United States\n/Australian Armada", "Disguise ","Exit");//Replace the team1,2,3 to your game teams name and colors, by /team1 or /team2 or / team3 the player gets disguise to enemy soldier but don't changes its team
return 1;
}
return 1;
}
Okay edits are done I included an example of your code as if your like my ZCMD will just come to you.