Jump to content

help Easter event quest


Recommended Posts

  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

You can do something like this

when item_vnum.use begin
    local t = get_global_time() - item.get_socket(1)
    local n = item.get_socket (0)
    if t >= 1800 then
        new_christmas_gift_box.gift(item.get_id())
        item.set_socket(1, get_global_time())
        if n == 9 then
            item.remove()
        else
            item.set_socket(0, n + 1)
        end
        syschat("The item had 10 uses, you can open it".. 9 - n .." more time(s).")
    else
        syschat("You can open it again in ".. 31 - t / 60 .." minute(s)!")
    end
end
Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

Announcements



×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.