27.07.2015, 12:21
Try debug your code maybe like this:
If you don't get the message, that's the real y_commands problem, do you use OnPlayerCommandPerfomed or OnPlayerCommandReceived??
Код:
YCMD:shop(playerid,params[],help) { sendclientmessage(playerid, -1, "Command Called"); new listtext[512],substr[40]; if(help) { sendclientmessage(playerid, -1, "Help Called"); SEM(playerid,"CMDINFO: Displays shop to buy special weapons!"); return 1; } forex(i, 13) { if(PlayerInfo[playerid][WeaponsPurchased][i]) { format(substr,sizeof(substr),"%s - {33AA33}PURCHASED\n",GunNames[SelledGun[i][Weaponid]]); } else { format(substr,sizeof(substr),"%s - $%d\n",GunNames[SelledGun[i][Weaponid]],SelledGun[i][Price]); } strcat(listtext,substr,sizeof(listtext)); } ShowPlayerDialog(playerid,DIALOG_BUY_GUN,DIALOG_STYLE_LIST,"Guns Shop",listtext,"Buy","Exit"); return 1; }