23.03.2017, 12:08
Hi, i want create dialog style input where i can type name of Item and destroy it, i make this:
Response:
And i get:
What i must change? maybe i do a mistake, idk
Код:
if(strcmp("/destroy", cmdtext, true) == 0) { if(gTeam[playerid] == TEAM_XX) { SendClientMessage(playerid, COLOR_RED, "You cant use this command as Zombie"); return 1; } ShowPlayerDialog(playerid,67,DIALOG_STYLE_INPUT,"Destroy","Item Name\n Item name:","Destroy","Quit"); }
Response:
Код:
if(dialogid==67){ new params[64]; strcat(params,inputtext[6]); if(response){ if(inputtext[playerid] == params) { if(!PlayerHasItem(playerid,params))return SendClientMessage(playerid,-1,"You dont have this item!"); RemoveItem(playerid,params,1); } return 1; } return 0; }
Код:
error 033: array must be indexed (variable "params")