Forum

> > CS2D > Scripts > Menu!?
Forums overviewCS2D overview Scripts overviewLog in to reply

English Menu!?

17 replies
To the start Previous 1 Next To the start

old Menu!?

Cons
User Off Offline

Quote
Hey guys, can please anyone help me, just show me how to do different Menus For Lua

Thanks

old Re: Menu!?

Jhony
User Off Offline

Quote
user Cons has written
Hey guys, can please anyone help me, just show me how to do different Menus For Lua

Thanks


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
addhook("serveraction","lolz") -- act
function lolz(id,a) -- fuck yeah
if a == 1 then --f2
menu(id, "Settings,blablabla,blablalbal")
end
end

addhkook("menu","update")
function update(id,tittle,button) -- act == action
if tittle = "Settings" then
if button == 1 then
                              -- your act here
elseif button = 2 then 
                               -- your act here 
end
end

is example

old Re: Menu!?

Cons
User Off Offline

Quote
user Jhony has written
user Cons has written
Hey guys, can please anyone help me, just show me how to do different Menus For Lua

Thanks


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
addhook("serveraction","lolz") -- act
function lolz(id,a) -- fuck yeah
if a == 1 then --f2
menu(id, "Settings,blablabla,blablalbal")
end
end

addhkook("menu","update")
function update(id,tittle,button) -- act == action
if tittle = "Settings" then
if button == 1 then
                              -- your act here
elseif button = 2 then 
                               -- your act here 
end
end

is example


I know how to make simple menu, i wanna make differents style of menus! ty
edited 1×, last 08.03.18 04:48:14 am

old Re: Menu!?

Bowlinghead
User Off Offline

Quote
I dont know what user Cons mean.

Do you mean this?
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
addhook("serveraction","lolz") -- act
function lolz(id,a) -- fuck yeah
if a == 1 then --f2
menu(id, "Settings,blablabla,blablalbal")
elseif a == 2 then --f3
menu(id,"Bla,bla") -- Note: You need a different name
end
end

addhkook("menu","update")
function update(id,tittle,button) -- act == action
if tittle == "Settings" then
if button == 1 then
-- your act here
elseif button == 2 then
-- your act here
end
elseif tittle == "Bla" then
if button == 1 then
-- your act here
end
end
end
God damn, I hate untabbed codes...
edited 1×, last 17.03.12 03:54:14 am

old Re: Menu!?

Cons
User Off Offline

Quote
user Bowlinghead has written
I dont know what user Cons mean.

Do you mean this?
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
addhook("serveraction","lolz") -- act
function lolz(id,a) -- fuck yeah
if a == 1 then --f2
menu(id, "Settings,blablabla,blablalbal")
elseif a == 2 then --f3
menu(id,"Bla,bla") -- Note: You need a different name
end
end

addhkook("menu","update")
function update(id,tittle,button) -- act == action
if tittle == "Settings" then
if button == 1 then
-- your act here
elseif button == 2 then
-- your act here
end
elseif tittle == "Bla" then
if button == 1 then
-- your act here
end
end
end
God damn, I hate untabbed codes...


No, I just wanna know how to make Different Styles Of Menus!
edited 1×, last 08.03.18 04:47:29 am

old Re: Menu!?

Bowlinghead
User Off Offline

Quote
Aaahhhh....
I understand.

You can't make other styles except the big menu.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
addhook("serveraction","lolz") -- act
function lolz(id,a) -- fuck yeah
if a == 1 then --f2
menu(id, "Settings@b,blablabla,blablalbal") -- Note
end
end

addhkook("menu","update")
function update(id,tittle,button) -- act == action
if tittle = "Settings" then
if button == 1 then
-- your act here
elseif button = 2 then
-- your act here
end
end

old Re: Menu!?

Cons
User Off Offline

Quote
user Bowlinghead has written
Aaahhhh....
I understand.

You can't make other styles except the big menu.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
addhook("serveraction","lolz") -- act
function lolz(id,a) -- fuck yeah
if a == 1 then --f2
menu(id, "Settings@b,blablabla,blablalbal") -- Note
end
end

addhkook("menu","update")
function update(id,tittle,button) -- act == action
if tittle = "Settings" then
if button == 1 then
-- your act here
elseif button = 2 then
-- your act here
end
end


Fixed :
More >


Thanks It Really Worked, Does we have any other Style?

old Re: Menu!?

Cons
User Off Offline

Quote
user Alistaire has written
user Cons has written
Does we have any other Style?


Invisible menu.


Dhaaa... And how to do it?! Nana

old Re: Menu!?

Alistaire
User Off Offline

Quote
menu(id, 'menuname@i,button1|comment,button2,button3)

old Re: Menu!?

Suprise
BANNED Off Offline

Quote
user Alistaire has written
menu(id, 'menuname@i,button1|comment,button2,button3)


Wow! I dont saw anything! Idi0t menu the invisible!

old Re: Menu!?

Cons
User Off Offline

Quote
user Alistaire has written
menu(id, 'menuname@i,button1|comment,button2,button3)


Fixed:
1
2
3
4
5
6
addhook("serveraction","Oo")
function Oo(id,a)
if a == 1 then
menu(id, "menuname@i,button1|comment,button2,button3") 
end
end

Like, its really Invisible?! Oo I just Cant See Nothing... But When i press F2 I cant change Weapon like when we open a normal menu...

So why we need buton names?
1
button1|comment,button2,button3

Oo

old Re: Menu!?

Yates
Reviewer Off Offline

Quote
He's trolling you, there is no way you can change how the menu looks like (You can only make it bigger with @b) other than in your own settings. Where you can only change the colour.

So stop being idiots, why in the world would DC add an invisible menu!?

old Re: Menu!?

Alistaire
User Off Offline

Quote
user Yates has written
why in the world would DC add an invisible menu!?


For passwords and to register when people click a number key.

old Re: Menu!?

Cons
User Off Offline

Quote
user Yates has written
He's trolling you, there is no way you can change how the menu looks like (You can only make it bigger with @b) other than in your own settings. Where you can only change the colour.

So stop being idiots, why in the world would DC add an invisible menu!?


Quote
But When i press F2 I cant change Weapon like when we open a normal menu...


Test it on your server and answer me!

old Re: Menu!?

Happy eyes
User Off Offline

Quote
Invisible menu exists, also bigger menu, menu with disabled buttons and menus with spaces. Check lua command menu
cs2d lua cmd menu

old Re: Menu!?

Alistaire
User Off Offline

Quote
user Happy eyes has written
Invisible menu exists, also bigger menu, menu with disabled buttons and menus with spaces. Check lua command menu
cs2d lua cmd menu


Thanks for repeating everything already posted here, mister obvious.
To the start Previous 1 Next To the start
Log in to reply Scripts overviewCS2D overviewForums overview