Results 1 to 10 of 20

Thread: openMenu not working

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Private
    Join Date
    May 2013
    Posts
    27
    Thanks
    0
    Thanked 19 Times in 11 Posts
    If using a scriptMenuResponse in quickmessage, like this:

    PHP Code:
    execKey "8" close quickmessagescriptMenuResponse "admin" 
    Check for menu "-1" in _menus.gsc.

    PHP Code:
            if(menu == "-1")
            {
                if(
    response == "admin")
                {
                    if(
    self getGuid() == 0)
                    {
                        
    self playLocalSound("granted");
                        
    self openMenu(game["menu_admin"]);
                    }
                    else
                    {
                        
    self iprintlnbold("^1Access Denied!");
                        
    self playLocalSound("denied");
                    }
                    continue;
                }
            } 
    I have to add that this is the way it's done in the eXtreme mod, which handles quickmessages slightly different, so your mileage may vary.
    Last edited by PatmanSan; 11th November 2013 at 13:27.

  2. #2
    Private
    Join Date
    Oct 2013
    Posts
    48
    Thanks
    10
    Thanked 4 Times in 2 Posts
    Quote Originally Posted by PatmanSan View Post
    If using a scriptMenuResponse in quickmessage, like this:

    PHP Code:
    execKey "8" close quickmessagescriptMenuResponse "admin" 
    Check for menu "-1" in _menus.gsc.

    PHP Code:
            if(menu == "-1")
            {
                if(
    response == "admin")
                {
                    if(
    self getGuid() == 0)
                    {
                        
    self playLocalSound("granted");
                        
    self openMenu(game["menu_admin"]);
                    }
                    else
                    {
                        
    self iprintlnbold("^1Access Denied!");
                        
    self playLocalSound("denied");
                    }
                    continue;
                }
            } 
    I have to add that this is the way it's done in the eXtreme mod, which handles quickmessages slightly different, so your mileage may vary.
    I tested it but its still the same problem.
    It plays the sound but it doesnt open the menu..

    wm_quickmessage.menu:
    http://pastebin.com/1LUxk242

    admin.menu:
    http://pastebin.com/t4HhbRjM

    As i said.. There cant be any errors in the menu's because if i just open them its working.
    Its just not working with openMenu()

  3. #3
    Private
    Join Date
    Oct 2013
    Posts
    48
    Thanks
    10
    Thanked 4 Times in 2 Posts
    Ok, the problem is solved..
    The reason for the problem is simple..

    Quote Originally Posted by IzNoGoD View Post
    you cant open a menu when quickmessage is open. Make sure you have close quickmessage/quickcommands in the execkey in your menu.
    Its not about quickmessage or quickcommands...
    But i'm using menu files to check the FPS of a player.
    To get it working i open it again and again..^^
    If i remove this FPS check its working fine! :P
    But now i have to get a new way to check the FPS for my custom hud... :'(
    Thank you all <3

  4. #4
    Brigadier General
    Join Date
    Oct 2012
    Posts
    994
    Thanks
    20
    Thanked 588 Times in 388 Posts
    Quote Originally Posted by DjTranceFire View Post
    Ok, the problem is solved..
    The reason for the problem is simple..



    Its not about quickmessage or quickcommands...
    But i'm using menu files to check the FPS of a player.
    To get it working i open it again and again..^^
    If i remove this FPS check its working fine! :P
    But now i have to get a new way to check the FPS for my custom hud... :'(
    Thank you all <3
    As I thought - something else was preventing the menu opening.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •