18.05.2013, 08:03
pawn Код:
new Wallet[MAX_PLAYERS][24],Wallet2[MAX_PLAYERS][24],Wallet3[MAX_PLAYERS][24]
pawn Код:
new format1[256];
if(PlayerInfo[playerid][pAdmin]==0)
{
format(Wallet[playerid],24,"Wallet1");
format(Wallet3[playerid],24,"Wallet3");
}
if(PlayerInfo[playerid][pAdmin]==1)
{
format(Wallet[playerid],24,"Wallet1");
format(Wallet2[playerid],24,"Wallet2");
format(Wallet3[playerid],24,"Wallet3");
}
format(format1,256,"%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n%s\n",Wallet[playerid],Wallet2[playerid],Wallet3[playerid]);
ShowPlayerDialog(playerid, DIALOG_P, DIALOG_STYLE_LIST,"Inventory:",format1,"Use","Close");
pawn Код:
case DIALOG_P:
{
if(response)
{
if(!strcmp(inputtext, Wallet[playerid], true))
{
SendClientMessage(playerid,COLOR_WHITE2,"You Picked Wallet1");
}
if(!strcmp(inputtext, Wallet2[playerid], true))
{
SendClientMessage(playerid,COLOR_WHITE2,"You Picked Wallet2");
}
if(!strcmp(inputtext, Wallet3[playerid], true))
{
SendClientMessage(playerid,COLOR_WHITE2,"You Picked Wallet3");
}
}
If you are admin = 0. If you pick Wallet you get Wallet and Wallet2 message
If you pick Wallet3 you get wallet2 and wallet3 message. Any ideas?