hey, i trying to create a box with giving item from table
can someone help? thanks
Lua:
table {
[2160] = {chance = 1000} -- 1%
[2152] = {chance = 2500} -- 2,5% ............
....
...
...
..
}
rand = math.rand(1,100000)
if(rand <= chance) then
player:addItem(?,?)
end
can someone help? thanks