Forum

> > CS2D > Scripts > How many of you use UniMenu?
Forums overviewCS2D overview Scripts overviewLog in to reply

English How many of you use UniMenu?

8 replies
To the start Previous 1 Next To the start

Poll Poll

Do you use it in your scripts?

Only registered users are allowed to vote
Yes, on a running server
3.70% (1)
Yes, on my offline/development server
0.00% (0)
I'm planning to use it
0.00% (0)
Not anymore
0.00% (0)
No
81.48% (22)
I have heard of it
14.81% (4)
27 votes cast

old Poll How many of you use UniMenu?

VADemon
User Off Offline

Quote
I'm currently working (call it an "update") on file cs2d [EngiN33R] UniMenu , refactoring the code (oh, dear user EngiN33R, it is a mess ), improving it and currently planning to slightly change the way the menus are scripted to make the menu scripting easier, faster and slightly reduce the memory consumption.

This may eventually break your current menus, hence the poll to get to know how many people are using it.

My plan is to change the structure of how menus are scripted (allow custom data per menu entry) and as a side effect extend the functions' arguments which in theory could allow you to write a single function with different data values fed in to make a whole menu (e.g. a buy menu)
As of now you must write one function per menu entry (which is a lot of work) or use custom tables for additional data (many newbie scripters won't pull it)

In case of success: I will ask user EngiN33R if he'd like to update his script with my version

old Re: How many of you use UniMenu?

Nekomata
User Off Offline

Quote
I tried it and left it after hassling around, but if you could make an improved and atleast semi-newbie proof version of it, I'd definitely try it out and if dynamic, replace it with what I currently have. ;0

old Re: How many of you use UniMenu?

VADemon
User Off Offline

Quote
@user _Yank: Well I didn't think that far. Thanks for the idea (I didn't go into your code though, it looks too unfamiliar hence I hope I got your idea correctly) - each menu button and its description can be made functions to customize the menu even further.

@user Nekomata: I've only tried once (YOTO) and never wanted to deal with CS2D menus again. I praise Lord Engi for making UniMenu.

@user omg: Here is not visiting the site as often as he used to, but he is reachable unlike me, who sometimes just goes lost for seemingly no reason.

Test version >


UPDATE:
Job's done!

unimenu.lua
unimenu_menus.lua

Full Changelog: >


Installation: put everything in the autorun folder.

Test script to play with Unimenu (only opens up the default examples from unimenu_menus.lua)
1
2
3
4
5
6
7
8
addhook("say", "asay")
function asay(id, txt)
	if txt == "uni_old" then
		unimenu(id, true, "example_menu_old", 1)
	elseif txt == "uni_new" then
		unimenu(id, true, "example_menu_new", 1)
	end
end
edited 2×, last 02.09.15 06:21:50 pm

old Re: How many of you use UniMenu?

EngiN33R
Moderator Off Offline

Quote
You have my full support with this (it really is a mess, I wasn't that good then). If this version is final, I can either reupload it instead of mine or let you upload an updated/remastered version separately.

old Re: How many of you use UniMenu?

Nekomata
User Off Offline

Quote
I worked days with the implemented cs2d menus and finally created something plausible and working for a script I'm working on, ofcourse with a loss of sanity and a part of my existence.

The update looks noice and easy, will try it.

old Re: How many of you use UniMenu?

VADemon
User Off Offline

Quote
I'm going to stop with the 2.1 update

Changelog 2.1:
ADDED
buttonData can also be a function now (called whenever the menu is constructed)
~ see this for an example

ADDED
unimenu_addButton can initialize functions instantly, saving returned string values to the menu table (to prevent tons of function calls during menu construction)
ADDED
Leave hook to delete temporary data of old players


I'll ask @user EngiN33R: to change his upload, because I don't want to have two different versions of the same script here.
...although a new upload would attract new comers and those who pay 0 attention to the stuff on the forums
To the start Previous 1 Next To the start
Log in to reply Scripts overviewCS2D overviewForums overview