Well, not working.
pawn Код:
if(dialogid == 7) {
if(strcmp(inputtext,"reset",true) == 0) {
for(new i = 0; i < 4; i++) {
if(PlayerWeapons[playerid][i] != -1) {
PlayerWeapons[playerid][i] = -1;
}
}
SetPVarInt(playerid,"SpawnCount",1);
SendClientMessage(playerid,white,"Your spawn weapons have been resetted.");
return SpawnDialog(playerid);
}
if(GetPVarInt(playerid,"SpawnCount") == 3) { SpawnDialog(playerid); return SendClientMessage(playerid,white,"You must reset your spawn weapons to choose new ones."); }
if(strcmp(inputtext,"1",true) == 0) {
PlayerWeapons[playerid][GetPVarInt(playerid,"SpawnCount")] = 24;
PlayerWeapons[playerid][0] += 50;
format(text,sizeof(text),"%i.: Desert Eagle",GetPVarInt(playerid,"SpawnCount"));
SendClientMessage(playerid,white,text);
SetPVarIntEx(playerid, "NameOfPVar", +, 1);
return SpawnDialog(playerid);
}else if(strcmp(inputtext,"2",true) == 0) {
PlayerWeapons[playerid][GetPVarInt(playerid,"SpawnCount")] = 25;
PlayerWeapons[playerid][0] += 80;
format(text,sizeof(text),"%i.: Shotgun",GetPVarInt(playerid,"SpawnCount"));
SendClientMessage(playerid,white,text);
SetPVarIntEx(playerid, "NameOfPVar", +, 1);
return SpawnDialog(playerid);
} else if(strcmp(inputtext,"3",true) == 0) {
PlayerWeapons[playerid][GetPVarInt(playerid,"SpawnCount")] = 27;
PlayerWeapons[playerid][0] += 100;
format(text,sizeof(text),"%i.: Combat Shotgun",GetPVarInt(playerid,"SpawnCount"));
SendClientMessage(playerid,white,text);
SetPVarIntEx(playerid, "NameOfPVar", +, 1);
return SpawnDialog(playerid);
} else if(strcmp(inputtext,"4",true) == 0) {
PlayerWeapons[playerid][GetPVarInt(playerid,"SpawnCount")] = 29;
PlayerWeapons[playerid][0] += 120;
format(text,sizeof(text),"%i.: MP5",GetPVarInt(playerid,"SpawnCount"));
SendClientMessage(playerid,white,text);
SetPVarIntEx(playerid, "NameOfPVar", +, 1);
return SpawnDialog(playerid);
} else if(strcmp(inputtext,"5",true) == 0) {
PlayerWeapons[playerid][GetPVarInt(playerid,"SpawnCount")] = 30;
PlayerWeapons[playerid][0] += 140;
format(text,sizeof(text),"%i.: AK-47",GetPVarInt(playerid,"SpawnCount"));
SendClientMessage(playerid,white,text);
SetPVarIntEx(playerid, "NameOfPVar", +, 1);
return SpawnDialog(playerid);
} else if(strcmp(inputtext,"6",true) == 0) {
PlayerWeapons[playerid][GetPVarInt(playerid,"SpawnCount")] = 31;
PlayerWeapons[playerid][0] += 180;
format(text,sizeof(text),"%i.: M4",GetPVarInt(playerid,"SpawnCount"));
SendClientMessage(playerid,white,text);
SetPVarIntEx(playerid, "NameOfPVar", +, 1);
return SpawnDialog(playerid);
} else if(strcmp(inputtext,"7",true) == 0) {
PlayerWeapons[playerid][GetPVarInt(playerid,"SpawnCount")] = 33;
PlayerWeapons[playerid][0] += 150;
format(text,sizeof(text),"%i.: Country Rifle",GetPVarInt(playerid,"SpawnCount"));
SendClientMessage(playerid,white,text);
SetPVarIntEx(playerid, "NameOfPVar", +, 1);
return SpawnDialog(playerid);
} else if(strcmp(inputtext,"8",true) == 0) {
PlayerWeapons[playerid][GetPVarInt(playerid,"SpawnCount")] = 34;
PlayerWeapons[playerid][0] += 250;
format(text,sizeof(text),"%i.: AK-47",GetPVarInt(playerid,"SpawnCount"));
SendClientMessage(playerid,white,text);
SetPVarIntEx(playerid, "NameOfPVar", +, 1);
return SpawnDialog(playerid);
} else if(strcmp(inputtext,"9",true) == 0 || strcmp(inputtext,"back",true) == 0) {
format(text,sizeof(text),"Total Payment on spawn: %i",PlayerWeapons[playerid][0]);
SendClientMessage(playerid,white,text);
return Dialog(playerid,"ammu");
} else if(strcmp(inputtext,"release",true) == 0) {
return release(playerid);
} else {
return SpawnDialog(playerid);
}
}