createUseable

Creates a useable item with a callback function.

Parameters:

  • item (string): Item name

  • func (function): Callback function when item is used

Example:

ps.createUseable('bandage', function(source, item)
    -- Heal player logic
    print("Player used bandage")
end)

Last updated