I know how to make invisible menu
example: menu(id,"Select class@i,Soldier")
but how do i make buttons?
Scripts
Invisible menu
Invisible menu
1

Sorry for this but it's more easy you create e Basic Menu.
This can close now menu(id,"Select class@i,Soldier")
menu function.
hudtxt2 or
image (and co.) to draw something on the player's screen, making the menu visible again but on your own way.
men = 2
addhook ("parse","menu")
function menu(cmd)
if cmd=="otm" and men==2 then
men = 1
parse ("sv_sound2 1 weapons/click.wav")
parse ("sv_fow 1")
parse ('hudtxt2 1 1 "©000255000Fow On" 320 240 0')
parse ('hudtxt2 1 2 "©255000000Fow Off" 320 250 0')
elseif cmd=="otm" and men==1 then
men = 2
parse ("sv_sound2 1 weapons/click.wav")
parse ("sv_fow 0")
parse ('hudtxt2 1 1 "©255000000Fow On" 320 240 0')
parse ('hudtxt2 1 2 "©000255000Fow Off" 320 250 0')
end
end
addhook ("spawn","initial")
function initial(id)
if id==1 then
men = 2
parse ('hudtxt2 1 1 "©255000000Fow On" 320 240 0')
parse ('hudtxt2 1 2 "©255000000Fow Off" 320 250 0')
end
end
addhook ("spawn","themenu")
function themenu(p)
parse ("bind mouse3 otm")
end
When u click the Mouse3 the FOW will be changed and the menu will appear on the center of your screenmen = 2
addhook ("serveraction","menu")
function menu(id,action)
if action==1 and men==2 then
men = 1
parse ("sv_sound2 1 weapons/click.wav")
parse ("sv_fow 1")
parse ('hudtxt2 1 1 "©000255000Fow On" 320 240 0')
parse ('hudtxt2 1 2 "©255000000Fow Off" 320 250 0')
elseif action==2 then
parse ('hudtxt2 1 1 "" 320 240 0')
parse ('hudtxt2 1 2 "" 320 250 0')
else
men = 2
parse ("sv_sound2 1 weapons/click.wav")
parse ("sv_fow 0")
parse ('hudtxt2 1 1 "©255000000Fow On" 320 240 0')
parse ('hudtxt2 1 2 "©000255000Fow Off" 320 250 0')
end
end

men = 2
addhook ("serveraction","menu")
function menu(id,action)
if action==1 and men==2 then
men = 1
parse ("sv_sound2 1 weapons/click.wav")
parse ("sv_fow 1")
parse ('hudtxt2 1 1 "©000255000Soldier" 320 240 0')
parse ('hudtxt2 1 2 "©255000000Awper" 320 250 0')
elseif action==2 then
parse ('hudtxt2 1 1 "" 320 240 0')
parse ('hudtxt2 1 2 "" 320 250 0')
else
men = 2
parse ("sv_sound2 1 weapons/click.wav")
parse ("sv_fow 0")
parse ('hudtxt2 1 1 "©255000000Soldier" 320 240 0')
parse ('hudtxt2 1 2 "©000255000Awper" 320 250 0')
end
end
addhook("spawn","chooseclass")
function chooseclass(id)
if (men==1) then
return "40,80";
elseif (men==2) then
return "35";
end
end
Not Tested
Probably it works.
1
