Raised This Month: $ Target: $400
 0% 

Which is the maximun len for a menu?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Unlimited!
BANNED
Join Date: Apr 2009
Old 04-13-2009 , 11:57   Which is the maximun len for a menu?
Reply With Quote #1

I have this menu and sometimes it isn't shown, it doesen't cut, it doesen't show. Another times it does.

PHP Code:
public show_menu_stats(id)
{
    
// Player disconnected
    
if (!is_user_connected(id))
    return;
    
    static 
menu[450], len
    len 
0
    
static name[27]
    
get_user_name(idname26)
    
len += formatex(menu[len], sizeof menu len"\yEstadisticas de jugador^n^n")
    
len += formatex(menu[len], sizeof menu len"\yAlias:\w %s^n"name)
    
len += formatex(menu[len], sizeof menu len"\yAP:\w %d \y Clase Humana: \w%s^n"g_ammopacks[id], level_name[ID_CLASE])
    
len += formatex(menu[len], sizeof menu len"\yAP para proximo nivel:\w %d^n",  g_nextlevel[id] - g_ammopacks[id])
    
len += formatex(menu[len], sizeof menu len"\yNiveles para proxima clase:\w %d^n",  15 - (g_level[id] - 15*ID_CLASE))
    
len += formatex(menu[len], sizeof menu len"\yProxima clase:\w %s^n"level_name[ID_CLASE 1])
    
len += formatex(menu[len], sizeof menu len"\yPuntos humanos:\w %d\y Puntos zombie:\w %d^n"g_h_points[id], g_z_points[id])
    
len += formatex(menu[len], sizeof menu len"\yPuntos de danio:\w %d\y Bonifi. de danio:\w %d^n"g_h_updamage[id], g_h_updmg[id])
    
len += formatex(menu[len], sizeof menu len"\yPuntos de vida:\w %d\y Bonifi. de vida:\w %d^n"g_z_uphealth[id], g_z_uphp[id])
    
len += formatex(menu[len], sizeof menu len"\yHumanos Infectados:\w %d^n"g_stats_2[id])
    
len += formatex(menu[len], sizeof menu len"\yZombies Matados:\w %d^n"g_stats_1[id])
    
//len += formatex(menu[len], sizeof menu - 1 - len, "\yTiempo Jugado:\w %s %H horas^n", jugado)
    
    
show_menu(idKEYSMENUmenu, -1"Stats")

Unlimited! is offline
Empowers
BANNED
Join Date: Feb 2009
Location: Ukraine
Old 04-13-2009 , 11:59   Re: Which is the maximun len for a menu?
Reply With Quote #2

PHP Code:
menu[450
450 is the max len.
Change that to values that u need.
Empowers is offline
Send a message via ICQ to Empowers
Unlimited!
BANNED
Join Date: Apr 2009
Old 04-13-2009 , 12:15   Re: Which is the maximun len for a menu?
Reply With Quote #3

Quote:
Originally Posted by Empowers View Post
PHP Code:
menu[450
450 is the max len.
Change that to values that u need.
I know that, but that isn't the matter. If that len was short, the menu would shown cut
ie:
instead of
Quote:
Hello my friend
it'd be
Quote:
Hello my fr
What I mean is a limit for HL engine for sending big menues...

edit: I even tried by using [1000] and it didn't worked.

Last edited by Unlimited!; 04-13-2009 at 12:19.
Unlimited! is offline
Empowers
BANNED
Join Date: Feb 2009
Location: Ukraine
Old 04-13-2009 , 12:18   Re: Which is the maximun len for a menu?
Reply With Quote #4

Hmm.. I saw the same.. When i was translating menu to russian.. Russian letters are to big in cs, so in long lines ends were cut
Empowers is offline
Send a message via ICQ to Empowers
Unlimited!
BANNED
Join Date: Apr 2009
Old 04-13-2009 , 12:20   Re: Which is the maximun len for a menu?
Reply With Quote #5

Quote:
Originally Posted by Empowers View Post
Hmm.. I saw the same.. When i was translating menu to russian.. Russian letters are to big in cs, so in long lines ends were cut
Yes but here they aren't cut. The menu doesen't even show up....
Unlimited! is offline
Empowers
BANNED
Join Date: Feb 2009
Location: Ukraine
Old 04-13-2009 , 12:23   Re: Which is the maximun len for a menu?
Reply With Quote #6

Maybe somethink with menu menu try to comment some lines..
Empowers is offline
Send a message via ICQ to Empowers
Unlimited!
BANNED
Join Date: Apr 2009
Old 04-13-2009 , 12:37   Re: Which is the maximun len for a menu?
Reply With Quote #7

Sorry I fixed it, it was a n00b error
Unlimited! is offline
YamiKaitou
Has a lovely bunch of coconuts
Join Date: Apr 2006
Location: Texas
Old 04-13-2009 , 12:38   Re: Which is the maximun len for a menu?
Reply With Quote #8

Quote:
Originally Posted by Unlimited! View Post
Sorry I fixed it, it was a n00b error
Saying the fix will assist others who get the same error
__________________
ProjectYami Laboratories

I do not browse the forums regularly anymore. If you need me for anything (asking questions or anything else), then PM me (be descriptive in your PM, message containing only a link to a thread will be ignored).
YamiKaitou is offline
Unlimited!
BANNED
Join Date: Apr 2009
Old 04-13-2009 , 12:39   Re: Which is the maximun len for a menu?
Reply With Quote #9

Quote:
Originally Posted by YamiKaitou View Post
Saying the fix will assist others who get the same error
Checking the size of an array LOL
Unlimited! 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 02:15.


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