Forum

> > CS2D > Scripts > menu shop
Forums overviewCS2D overview Scripts overviewLog in to reply

English menu shop

6 replies
To the start Previous 1 Next To the start

old menu shop

thesk5tera
User Off Offline

Quote
i need help when i press f2 i have menu(,Zombie Shop,Humain Shop....)
when press Humain shop i don't see the next menu(Speed|50 ap....)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
addhook("serveraction","lightz")
function lightz(p,a)
local t = player(p,'team')
	if (a == 2 and t == 2) then
		if (light01[p] == 1) then
			light01[p]=0
			freeimage(light[p])
		else 
			light01[p]=1
			light[p]=image("gfx/yates/lua/spot.png",1,1,200+p)
			imageblend(light[p],1)
			imagecolor(light[p],200,200,100)
			imagealpha(light[p],0.7)
		end
		return 1
	end
	if a == 1 then
		menu(p,"Main Menu,Humain Shop| For Humain,Zombie Shop| For Zombie,Hats| For VIP Admin")
	end
end

addhook("menu","menu_hook")
function menu_hook(p,title,button)
local team = player(p,'team')
if title=="Humain Shop" then
if (team == 2) then
menu(p,"Speed| 50ap,Heal Potion| 50ap,Super Heal Potion| 70ap,Kevlar Armor| 50ap,Super Kevlar Armor| 70ap,Medic Armor| 90ap,M249| 500ap,M3| 200ap,Next >>")
end
end
end
i need help

old Re: menu shop

Gajos
BANNED Off Offline

Quote
Make others like this:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
addhook('serveraction','serveraction_hook')
function serveraction_hook(id,a)
	local t = player(id,'team')
	if a == 2 and t == 2 then
		if light01[id] == 1 then
			light01[id] = 0
			freeimage(light[id])
		else 
			light01[id] = 1
			light[id] = image('gfx/yates/lua/spot.png',1,1,200 + id)
			imageblend(light[id],1)
			imagecolor(light[id],200,200,100)
			imagealpha(light[id],0.7)
		end
		return 1
	elseif a == 1 then
		menu(id,'Main Menu,Humain Shop| For Humain,Zombie Shop| For Zombie,Hats| For VIP Admin')
	end
end

addhook('menu','menu_hook')
function menu_hook(id,title,button)
	local team = player(id,'team')
	if title == 'Main Menu' then
		if team == 2 then
			if button == 1 then
				menu(id,'Speed| 50ap,Heal Potion| 50ap,Super Heal Potion| 70ap,Kevlar Armor| 50ap,Super Kevlar Armor| 70ap,Medic Armor| 90ap,M249| 500ap,M3| 200ap,Next >>')
			end
		end
	end
end

old Re: menu shop

Yates
Reviewer Off Offline

Quote
Seriously @user thesk5tera, you will never be able to edit any script if you take things to be as stupid as this.

Making a menu to buy items won't magically make the items become real, check out zp_items and add your shit there.

Then go to zp_func_m, and edit the menu title and buttons. zp_func will give you the hook zp_menu and from there you can edit the Main Menu to do what you want it to do.

old Re: menu shop

Yates
Reviewer Off Offline

Quote
Learn English or don't bother asking. I seriously can't help you like this and if further spammed by PM won't bother trying.

old Re: menu shop

Yates
Reviewer Off Offline

Quote
Stop trying to edit mods. There, that's all the help I can give.
To the start Previous 1 Next To the start
Log in to reply Scripts overviewCS2D overviewForums overview