AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   menu_additem (https://forums.alliedmods.net/showthread.php?t=171206)

Diegorkable 11-03-2011 07:47

menu_additem
 
I have noticed that menu_additem can add a string that is a maximum 19 len word. I noticed that because I tried adding the map name deathrun_mini_city_final and it added only deathrun_mini_city_. Is there any way I could make it maybe longer? (maybe from going to the function sma), will it cause problems if I make it longer?

MyPc 11-03-2011 09:30

Re: menu_additem
 
Quote:

Originally Posted by Diegorkable (Post 1589043)
I have noticed that menu_additem can add a string that is a maximum 19 len word. I noticed that because I tried adding the map name deathrun_mini_city_final and it added only deathrun_mini_city_. Is there any way I could make it maybe longer? (maybe from going to the function sma), will it cause problems if I make it longer?

You can always use old style menu ( iLen += .. )

Diegorkable 11-03-2011 13:28

Re: menu_additem
 
Never tried that before, is there anything you can link me to?

Emp` 11-03-2011 13:30

Re: menu_additem
 
Most likely you are limiting the size of the map name. Show your code.

Diegorkable 11-03-2011 16:20

Re: menu_additem
 
nah not really, the array size of the menu item is 70
anyways for testing I tried to menu_additem("deathrun..blblblal") and same, it looked the same.

Emp` 11-03-2011 19:04

Re: menu_additem
 
http://i.imgur.com/2xreR.png

It seems that item names get cut off at 78 (but that is definitely not 19)

Also you can see that the menu gets cut short too (no next or exit displayed)

If you want help, show us your code.

edit: Plugin from screenshot: Smart Slash

MyPc 11-04-2011 01:16

Re: menu_additem
 
Quote:

Originally Posted by Emp` (Post 1589469)
http://i.imgur.com/2xreR.png

It seems that item names get cut off at 78 (but that is definitely not 19)

Also you can see that the menu gets cut short too (no next or exit displayed)

If you want help, show us your code.

edit: Plugin from screenshot: Smart Slash

you used formatex() with 128chrs i think it matters what his string len ..

fysiks 11-04-2011 01:18

Re: menu_additem
 
I made a similar mistake once so:

Quote:

Originally Posted by Emp` (Post 1589234)
Show your code.



All times are GMT -4. The time now is 14:26.

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