Dude in mSelection
#1

Hi, I have two questions.

I'm remodeling the Toys that brings GM place I occupy and to choose the toys mSelection bla bla bla everything perfect the problem is when I choose the toys were placed in the menu of toys in slot 1 then I put that show the Dialog with ShowDialog (playerid. .. but not how to make when I Choose for example the seven slots keep the toys are there.

The other question is because when I am in the menu and pulse mSelection Escape the menu stays there, I mean the request is canceled but the "TextDraw" nose out, click-only when "cancel" is removed TextDraw


OnPlayerModelSelection

Код HTML:
if(listid == toyslist)
                {
                     if(response)
                          {
                            new index, string[128];
                            ShowDialog(playerid, 19);
                            SendClientMessage(playerid, COLOR_WHITE, "Elige el slot donde lo colocaras.");
                            PlayerInfo[playerid][pToyModel][index] = modelid;
	                        GiveZaiatMoney(playerid, -300);
	                        format(string, sizeof(string), "* %s ha comprado un toy por $300.", RPN(playerid));
 	                        SendNearbyMessage(playerid, 15, string, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE);
 	                        SendClientMessage(playerid, COLOR_WHITE, " Puedes ver y editar los toys usando /toys.");
                          }
                     else SendClientMessage(playerid, 0xFFFF00FF, "As salido del catalogo de skins");
               return 1;
            }
Dialogs
Код HTML:
else if(dialogid == 19)
	{
	    if(response)
	    {
	        switch(listitem)
	        {
	            case 0: toyslot[playerid] = 0; 
                    case 1: toyslot[playerid] = 1; 
                    case 2: toyslot[playerid] = 2; 
                    case 3: toyslot[playerid] = 3; 
                    case 4: toyslot[playerid] = 4;
	            case 5: toyslot[playerid] = 5; 
                    case 6: toyslot[playerid] = 6; 
                    case 7: toyslot[playerid] = 7; 
                    case 8: toyslot[playerid] = 8; 
                    case 9: toyslot[playerid] = 9;
	        }
	        new index = toyslot[playerid];
		    if(PlayerInfo[playerid][pToyModel][index] == 0)
		    {
		        ShowDialog(playerid, 19);
		    }
		    else
		    {
	        	ShowDialog(playerid, 28);
	        }
	    }
	}
Commands
Код HTML:
CMD:ctoys(playerid, params[])
{
	new idx = GetPlayerVirtualWorld(playerid)-100;
	if(!IsPlayerLoggedIn(playerid)) return SendClientMessage(playerid, COLOR_GREY, "No estas logueado.");
	if(idx > 0 && idx < MAX_BIZ && BizInfo[idx][bType] != 2 || idx < 1 || idx > MAX_BIZ) return SendClientMessage(playerid, COLOR_GREY, "No estas en la tienda de Ropa.");
	if(BizInfo[idx][bProducts] < 1) return SendClientMessage(playerid, COLOR_GREY, "El negocio tiene los productos agotados.");
	if(PlayerInfo[playerid][pMoney] < 300) return SendClientMessage(playerid, COLOR_GREY, "No tienes suficiente dinero.");
        {
		ShowModelSelectionMenu(playerid, toyslist, "Elige el Toys");
	}
	return 1;
}
ShowDialog OnPlayerModelSelection put in for nothing, that is, only the appearance of the dialog without any purpose.

That's all, thanks in advance

I speak Spanish because if there are some errors in translating :/ forgive me xd
Reply


Messages In This Thread
Dude in mSelection - by Rhino - 17.03.2013, 21:52

Forum Jump:


Users browsing this thread: 1 Guest(s)