12.10.2013, 16:14
pawn Код:
if(dialogid = DIALOG_WEPS1)
pawn Код:
if(dialogid == DIALOG_WEPS1)
pawn Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
switch(dialogid)
{
case DIALOG_WEPS1:
{
if(response)
{
switch(listitem)
{
case 0:
{
GameTextForPlayer(playerid, "Weapon Pack 1 chosen", 3500, 1);
GivePlayerWeapon(playerid, 4, 1);
GivePlayerWeapon(playerid, 22, 500);
GivePlayerWeapon(playerid, 25, 150);
GivePlayerWeapon(playerid, 28, 850);
GivePlayerWeapon(playerid, 31, 500);
GivePlayerWeapon(playerid, 33, 500);
SetPlayerArmour(playerid, 99.0);
}
case 1:
{
GameTextForPlayer(playerid, "Weapon Pack 2 chosen", 3500, 1);
GivePlayerWeapon(playerid, 16, 1);
GivePlayerWeapon(playerid, 24, 257);
GivePlayerWeapon(playerid, 27, 350);
GivePlayerWeapon(playerid, 30, 550);
GivePlayerWeapon(playerid, 35, 2);
SetPlayerArmour(playerid, 50);
}
case 2:
{
GameTextForPlayer(playerid, "Weapon pack 3 chosen", 3500, 1);
GivePlayerWeapon(playerid, 18, 2);
GivePlayerWeapon(playerid, 24, 500);
GivePlayerWeapon(playerid, 27, 360);
GivePlayerWeapon(playerid, 26, 50);
GivePlayerWeapon(playerid, 29, 500);
GivePlayerWeapon(playerid, 34, 500);
GivePlayerWeapon(playerid, 35, 4);
SetPlayerArmour(playerid, 25);
}
}
}
return 1;
}
}
return 0;
}