FaStDiE has written
I TESTED THIS! dont edit hooks and functions name cuz it result ERROR attempt to call nil value DONT EDIT
Quote
addhook("attack","hamthrow")
function hamthrow(id)
if (player(id,"weapontype") == 86) then
parse("sethealth "..id.." "..player(id,"health")+math.random(10,20))
msg2(source,"You have eaten a hamburger!")
return 1
end
end
addhook("drop","hamdrop")
function hamdrop(id,iid,type,ain,a,mode,x,y)
if type==86 then
return 1
end
return 0
end
addhook("say","getham")
function getham(p,txt,weapon)
if (txt=="!give_ham") then
parse("equip "..p.." 86")
return 1
end
end
function hamthrow(id)
if (player(id,"weapontype") == 86) then
parse("sethealth "..id.." "..player(id,"health")+math.random(10,20))
msg2(source,"You have eaten a hamburger!")
return 1
end
end
addhook("drop","hamdrop")
function hamdrop(id,iid,type,ain,a,mode,x,y)
if type==86 then
return 1
end
return 0
end
addhook("say","getham")
function getham(p,txt,weapon)
if (txt=="!give_ham") then
parse("equip "..p.." 86")
return 1
end
end
There i show your errors