Files
2026-06-01 12:46:52 +02:00

49 lines
886 B
Lua

function procAddItem( name , item_id , quantity ) -- Azia Mafia Bonus item
--253 Vous avez reçu : <B>#@item_name@#</B>.
--254 Vous avez reçu : <B>#@item_name@#</B> <B>(#@item_num@#)<B/>.
--[[
if gv("name") == "AhOuiOui" then
message("loot name = " .. name )
end
item_id = tonumber(item_id)
quantity = tonumber(quantity)
quantity2 = 1
insert_item(690303, math.random(1,10))
if math.random(1,10) == 10 then
if quantity > 1 then
quantity2 = math.random( 1 , tonumber(quantity) )
end
if quantity2 == 1 then
-- no quantity 253
text = sconv("@253" , "#@item_name@#" , "@" .. get_item_name_id(item_id) )
else
-- with quantity 254
text = sconv("@254" , "#@item_name@#" , "@" .. get_item_name_id(item_id) , "#@item_num@#" , quantity2 )
end
text = sconv("<#FFA500><bold>Bonus :<#FFFFFF> %s" , "%s" , text )
insert_item(item_id,quantity2)
message(text)
end
]]--
end