Forum

> > CS2D > Scripts > How to make another button?
Forums overviewCS2D overview Scripts overviewLog in to reply

English How to make another button?

7 replies
To the start Previous 1 Next To the start

old How to make another button?

Dovahkin
User Off Offline

Quote
example:rifles:click it:the informatin

>addhook("serveraction","noob")
addhook("menu", "mymenu")
function noob(id, nob)
if(nob==1) then
menu(id,"New Shop,Snipers,Rifles,Rpg,Armors,Items")
end
end
function mymenu(id,a,b)
if a=="New Shop" then
if b==1 then
menu(id,"Snipers,Awp:8000$,Scout:13000$")
end
end
end
elseif a == "Snipers" then

local mon = player(id,"money")
if b==1 and mon>500 then
parse("equip "..id.." 35")
parse("setmoney "..id.." "..mon-8000)
elseif mon<500 then

msg("©000255255You don't have money to buy this")
end
elseif a == "Snipers" then

local mon = player(id,"money")
if b==2 and mon>=13000 then
parse("equip "..id.." 34")
parse("setmoney "..id.." "..mon-13000)
elseif mon<13000 then

msg("©000255255You don't have money to buy this")
end
end
end

old Re: How to make another button?

Dovahkin
User Off Offline

Quote
firetounge41 has written
example:rifles:click it:the informatin

[code]addhook("serveraction","noob")
addhook("menu", "mymenu")
function noob(id, nob)
if(nob==1) then
menu(id,"New Shop,Snipers,Rifles,Rpg,Armors,Items")
end
end
function mymenu(id,a,b)
if a=="New Shop" then
if b==1 then
menu(id,"Snipers,Awp:8000$,Scout:13000$")
end
end
end
elseif a == "Snipers" then

local mon = player(id,"money")
if b==1 and mon>500 then
parse("equip "..id.." 35")
parse("setmoney "..id.." "..mon-8000)
elseif mon<500 then

msg("©000255255You don't have money to buy this")
end
elseif a == "Snipers" then

local mon = player(id,"money")
if b==2 and mon>=13000 then
parse("equip "..id.." 34")
parse("setmoney "..id.." "..mon-13000)
elseif mon<13000 then

msg("©000255255You don't have money to buy this")
end
end
end

old Re: How to make another button?

Kel9290
User Off Offline

Quote
That guy is spammer
More >

DC, he added [code] but not ended that :3
edited 5×, last 21.03.11 02:37:08 pm

old :(

Dovahkin
User Off Offline

Quote
im new i dont know
To the start Previous 1 Next To the start
Log in to reply Scripts overviewCS2D overviewForums overview