Menu, optimizing it
#3

Why dont you put these lines in the command that you type to show menu ?

pawn Код:
if(strcmp("/menu",cmdtext,5) == 0)
{
        gTeam[playerid] = TEAM_WSPD;
        SetPlayerColor(playerid, COLOR_BLUE);
        GivePlayerWeapon(playerid,24,100);
        GivePlayerWeapon(playerid,3,1);
        SendClientMessage(playerid, COLOR_WSPD, "You're on Cop Duty, shoot ($100) or jail ($150) some criminals")
        ShowMenuForPlayer(CopOnD,playerid);
        return 1;
     
}
Something like this should do it and then remove the lines from the cases like this

pawn Код:
if(CurrentMenu == CopOnD)
    {
    switch(row)
    {
   
        case 0:
        {
                SetPlayerSkin(playerid, 71);
            }
        case 1:
        {
                SetPlayerSkin(playerid, 280);
            }
        case 2:
        {
                SetPlayerSkin(playerid, 281);
            }
Reply


Messages In This Thread
Menu, optimizing it - by [WS]Hyper - 27.11.2009, 17:00
Re: Menu, optimizing it - by Backwardsman97 - 27.11.2009, 17:06
Re: Menu, optimizing it - by Peter_Corneile - 27.11.2009, 17:07
Re: Menu, optimizing it - by Backwardsman97 - 27.11.2009, 17:09
Re: Menu, optimizing it - by Peter_Corneile - 27.11.2009, 17:10
Re: Menu, optimizing it - by [WS]Hyper - 27.11.2009, 17:58
Re: Menu, optimizing it - by Niixie - 28.11.2009, 18:46
Re: Menu, optimizing it - by [WS]Hyper - 29.11.2009, 09:11
Re: Menu, optimizing it - by Niixie - 29.11.2009, 09:34

Forum Jump:


Users browsing this thread: 1 Guest(s)