Adding command to start dialog:
#1

Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{

	if(dialogid == 20320 && response)
    {
		switch(listitem)
		{
			case 0:
			{
			   ShowPlayerDialog(playerid, 20321, DIALOG_STYLE_LIST, "Take a look at my other 44's", "9mm($1000)\nSilenced 9mm($2000)", "OMGYES", "NiggaNO!");
            }
        }
    }
    if (dialogid == 20321 && response)
    {
	   switch(listitem)
	   {
		  case 0:
		  {
		  if(GetPlayerMoney(playerid) < 1000) return SendClientMessage(playerid, 0xFFFFFFFF, "Bro you broke");
		  GivePlayerWeapon(playerid, 22,100);
		  GivePlayerMoney(playerid, -1000);
		  SendClientMessage(playerid, 0xFFFFFFFF, "Let's kick some ass.");
		  }
		  case 1:
		  {
		  if(GetPlayerMoney(playerid) < 2000) return SendClientMessage(playerid, 0xFFFFFFFF, "Bro you broke");
		  GivePlayerWeapon(playerid, 23, 100);
		  GivePlayerMoney(playerid, -2000);
		  SendClientMessage(playerid, 0xFFFFFFFF, "Kick some silenced ass");
		  }
      }
   }

	return 1;
}
If someone can show me how to add a command to start this dialog?
Reply


Messages In This Thread
Adding command to start dialog: - by Bek_Loking - 24.05.2014, 21:29
Re: Adding command to start dialog: - by eXeDev - 24.05.2014, 22:13
Re: Adding command to start dialog: - by Bek_Loking - 24.05.2014, 22:13
Re: Adding command to start dialog: - by Matess - 24.05.2014, 22:17
Re: Adding command to start dialog: - by eXeDev - 24.05.2014, 22:18
Re: Adding command to start dialog: - by Bek_Loking - 24.05.2014, 22:42
Re: Adding command to start dialog: - by AndySedeyn - 24.05.2014, 22:47
Re: Adding command to start dialog: - by eXeDev - 24.05.2014, 22:48
Re: Adding command to start dialog: - by SickAttack - 24.05.2014, 22:50
! - by Bek_Loking - 24.05.2014, 23:01

Forum Jump:


Users browsing this thread: 2 Guest(s)