Raised This Month: $32 Target: $400
 8% 

[L4D2] Problems with the menu display


Post New Thread Reply   
 
Thread Tools Display Modes
Grey83
Veteran Member
Join Date: Dec 2014
Location: Ukraine
Old 08-25-2016 , 10:06   Re: [L4D2] Problems with the menu display
Reply With Quote #11

asherkin, sm_prop_ctrl (plugin which has a problem with display of the menu):
Spoiler

sm_telemanager (writed with SM1.6 sintax):
Spoiler

!settings (from SM1.8):
Spoiler

!admin (from SM1.8):
Spoiler
__________________

Last edited by Grey83; 08-25-2016 at 10:40.
Grey83 is offline
Grey83
Veteran Member
Join Date: Dec 2014
Location: Ukraine
Old 08-25-2016 , 10:32   Re: [L4D2] Problems with the menu display
Reply With Quote #12

Benoist3012, I have made these changes, but nothing was visible in a chat:
PHP Code:
        case MenuAction_DisplayItem:
        {
            if(
param == 6)
            {
                
char buffer[64];
                
Format(buffersizeof(buffer), "%s"cRelative[iMWorld[client]]);
                
PrintToChatAll("\x01Buffer: '\x03%s\x01'"buffer);
                return 
RedrawMenuItem(buffer);
            }
        } 
After these changes in a chat the text has appeared, but the menu all is also not visible:
PHP Code:
Menu BuildRotateMenu()
{
    
Menu rotatemenu = new Menu(Menu_RotateMENU_ACTIONS_ALL);
...

Buffer:
Spoiler
__________________

Last edited by Grey83; 08-25-2016 at 10:35.
Grey83 is offline
Benoist3012
Veteran Member
Join Date: Mar 2014
Location: CWave::ForceFinish()
Old 08-25-2016 , 14:21   Re: [L4D2] Problems with the menu display
Reply With Quote #13

Quote:
Originally Posted by Grey83 View Post
Benoist3012, I have made these changes, but nothing was visible in a chat:
PHP Code:
        case MenuAction_DisplayItem:
        {
            if(
param == 6)
            {
                
char buffer[64];
                
Format(buffersizeof(buffer), "%s"cRelative[iMWorld[client]]);
                
PrintToChatAll("\x01Buffer: '\x03%s\x01'"buffer);
                return 
RedrawMenuItem(buffer);
            }
        } 
Yeah I suspected you array cRelative[iMWorld[client]] to have nothing in it, something is probably wrong with this variable, all I can recommend you is to print it, before call the menu, when the menu is displayed (your code above) and after calling it.
If the 2 firsts prints are empty but not the third then you are taking to much time to store your string.
And if all of them (the 3 prints) are empty then I have no idea of what's going on.
__________________
Benoist3012 is offline
Grey83
Veteran Member
Join Date: Dec 2014
Location: Ukraine
Old 08-25-2016 , 14:35   Re: [L4D2] Problems with the menu display
Reply With Quote #14

Benoist3012, Your advice does not make sense: there was simply no event 'MenuAction_DisplayItem' until I added a parameter 'MENU_ACTIONS_ALL'

This array contains values:
PHP Code:
char cRelative[2][7] = {"entity""world"}; 
__________________
Grey83 is offline
Benoist3012
Veteran Member
Join Date: Mar 2014
Location: CWave::ForceFinish()
Old 08-25-2016 , 17:09   Re: [L4D2] Problems with the menu display
Reply With Quote #15

Then why are you giving me your resluts lol?
-Snip-
Anyway so it's a const char, saying it before would have been better, anyway the problem is from RedrawMenuItem then.
__________________

Last edited by Benoist3012; 08-25-2016 at 17:22. Reason: Wiki needs an update
Benoist3012 is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 18:53.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode