Unknown Known Command :D
#1

Here is the command
PHP код:
CMD:weapons(playeridparams[])
{
     if(
PInfo[playerid][Army]) {
     
ShowPlayerDialog(playeridDIALOG_WEAPONSDIALOG_STYLE_LIST"Weapons""AK47\nM4\nSniper Rifle""Buy""Cancel");
     }
     else
     {
     
SendClientMessage(playeridCOLOR_RED"You are not an army officer !");
     }

When i type it, it work and the dialog apear and the dialog work but at the same time it send me a client message that this command is unknow.

Please Help,REP++
Reply
#2

Where's '
pawn Код:
return 1;
Reply
#3

Quote:
Originally Posted by Bingo
Посмотреть сообщение
Where's '
pawn Код:
return 1;
I said before that i am a little bit donkey btw REP
and whats about the message that i have sent to You ??
Reply
#4

pawn Код:
CMD:weapons(playerid, params[])
{
     if(PInfo[playerid][Army]) {
     ShowPlayerDialog(playerid, DIALOG_WEAPONS, DIALOG_STYLE_LIST, "Weapons", "AK47\nM4\nSniper Rifle", "Buy", "Cancel");
     }
     else
     {
     SendClientMessage(playerid, COLOR_RED, "You are not an army officer!");
     return 1;
     }
}
Reply
#5

Quote:
Originally Posted by Bingo
Посмотреть сообщение
pawn Код:
CMD:weapons(playerid, params[])
{
     if(PInfo[playerid][Army]) {
     ShowPlayerDialog(playerid, DIALOG_WEAPONS, DIALOG_STYLE_LIST, "Weapons", "AK47\nM4\nSniper Rifle", "Buy", "Cancel");
     }
     else
     {
     SendClientMessage(playerid, COLOR_RED, "You are not an army officer!");
     return 1;
     }
}
Ok what about the message !!
Reply
#6

Quote:
Originally Posted by Bingo
Посмотреть сообщение
pawn Код:
CMD:weapons(playerid, params[])
{
     if(PInfo[playerid][Army]) {
     ShowPlayerDialog(playerid, DIALOG_WEAPONS, DIALOG_STYLE_LIST, "Weapons", "AK47\nM4\nSniper Rifle", "Buy", "Cancel");
     }
     else
     {
     SendClientMessage(playerid, COLOR_RED, "You are not an army officer!");
     return 1;
     }
}
Ehh not in the right place.
pawn Код:
CMD:weapons(playerid, params[])
{
     if(PInfo[playerid][Army]) {
          ShowPlayerDialog(playerid, DIALOG_WEAPONS, DIALOG_STYLE_LIST, "Weapons", "AK47\nM4\nSniper Rifle", "Buy", "Cancel");
     }else{
          SendClientMessage(playerid, COLOR_RED, "You are not an army officer!");
     }
     return 1;
}
Each command and callback should return a value of 1 or 0.
Returning 0 or not at all in a command will return "Unknown command"
Reply
#7

......
Reply
#8

wht is the gm? hope i can be mapper/scripter
Reply
#9

.....
Reply


Forum Jump:


Users browsing this thread: