Xycaleth Posted June 16, 2016 Posted June 16, 2016 It's possible but it would be specific to the OpenJK mod. Not all mods would be able to use it.
Xycaleth Posted June 16, 2016 Posted June 16, 2016 Why do you have so many menus? Asking out of curiosity
afi Posted June 16, 2016 Posted June 16, 2016 What do you need so many menus for tho... you know, you can do a lot with cvars etc
Lancelot Posted June 16, 2016 Posted June 16, 2016 I know I can do things with cvars but it's impossible in that case. I need multiple menus for a mod which I think will be released soon. And I need so many menus to make it great.Why don't you show us your mod in the WIP section of this forum? Everyone will get an idea of what the menus are supposed to look like, what they are for and so on. Maybe you will get more help with creating your menus by showing us what you already made.
ensiform Posted June 16, 2016 Posted June 16, 2016 I would make it memory limited only but I don't know where we can best put the freeing of memory and I tried using C++ stuff in SP which failed miserably So if @@Xycaleth or @@mrwonko want's to tackle replacing both MP and SP to use a resizing dynamic array like the species code, feel free.
ensiform Posted June 16, 2016 Posted June 16, 2016 Sure but in MP its still difficult I've created an issue on github so it can get looked at hopefully.
Futuza Posted June 16, 2016 Posted June 16, 2016 I would make it memory limited only but I don't know where we can best put the freeing of memory and I tried using C++ stuff in SP which failed miserably So if @@Xycaleth or @@mrwonko want's to tackle replacing both MP and SP to use a resizing dynamic array like the species code, feel free.I might be able to do that, no promises though, where's the code start that I should look at?
mrwonko Posted June 16, 2016 Posted June 16, 2016 I'd be interested in tackling this at some point, yes. But I have no idea when I'll get around to it.
ensiform Posted June 16, 2016 Posted June 16, 2016 ui_main.c / ui_main.cpp @@Darth Futuza Futuza likes this
ensiform Posted June 17, 2016 Posted June 17, 2016 @@Darth Futuza it is actually in ui_shared.c / ui_share.cpp my bad! menuDef_t Menus[MAX_MENUS]; // defined menus int menuCount = 0; // how many Futuza likes this
ensiform Posted June 17, 2016 Posted June 17, 2016 Define too much content lol. The parser for menu files does not have a restriction on filesize at all... So unless you've somehow run out of usable memory by the process then I don't see how there's an issue with total number of menus. The engine still hiccups at 64 parsed files it looks like for the botlib parser. (In MP)
ensiform Posted June 17, 2016 Posted June 17, 2016 The latter of which only applies to the gameinfo.dat file.
afi Posted June 18, 2016 Posted June 18, 2016 MAX_MENUITEMS is 512 in openJK so you're probably hitting that limit. Do you close a menu when you open a new one btw?
Recommended Posts