Problem with arguments
#3

No, its text example

CreateMenuEx(playerid,"header","text");

so it can be false or true ....

paramerters

HideMenuEx(playerid,bool:header,bool:text)

HideMenuEx(playerid,1,0);

so if is 1,1 it will hide all menu ( text and header )

if is 1,0 then will hide just header

else if 0,1 the will hide just text

here it is func

pawn Код:
stock HideMenuEx(playerid,bool:header,bool:text)
{
     if(header == true)
     {
       if(GetPVarInt(playerid,"KoristiMenuExHeader") == 1)
       {
         TextDrawHideForPlayer(playerid,Text:Header[playerid]);
         SetPVarInt(playerid,"KoristiMenuExHeader",0);
         TogglePlayerControllable(playerid, 1);
       }
       else
       {
          print("MenuEx: MenuEx header nemoze biti ugasen jer nije aktivan.");
       }
     }
     else if(text == true)
     {
        if(GetPVarInt(playerid,"KoristiMenuEx") == 1)
        {
           TextDrawHideForPlayer(playerid,Text:Text[playerid]);
           SetPVarInt(playerid,"KoristiMenuEx",0);
           TogglePlayerControllable(playerid, 1);
        }
        else
        {
          print("MenuEx: MenuEx text nemoze biti ugasen jer nije aktivan.");
        }
     }
     return 1;
}
Reply


Messages In This Thread
Problem with arguments - by DarkPower - 04.09.2010, 23:03
Re: Problem with arguments - by willsuckformoney - 04.09.2010, 23:17
Re: Problem with arguments - by DarkPower - 04.09.2010, 23:18
Re: Problem with arguments - by woot - 04.09.2010, 23:22
Re: Problem with arguments - by DarkPower - 04.09.2010, 23:24

Forum Jump:


Users browsing this thread: 1 Guest(s)