# Progressbar

## 📘 FRKN Progressbar Export

A custom progressbar system for FiveM, inspired by **QBCore.Functions.Progressbar**, but built into **frkn-notify**.

***

### 📌 Usage

```lua
exports['frkn-uikit']:Progressbar(
    "progressbar-1",                -- Default Progressbar Style
    "Drinking Water...",            -- Label (text displayed to the player)
    5000,                           -- Duration in milliseconds
    false,                          -- useWhileDead (false means player cannot use it while dead)
    true,                           -- canCancel (true means it can be cancelled by pressing keys like ESC/Backspace)
    {                               -- Disable Controls
        disableMovement = true,
        disableCarMovement = true,
        disableMouse = false,
        disableCombat = true,
    },
    {                               -- Animation details
        animDict = "mp_player_intdrink",
        anim = "loop_bottle",
        flags = 49,
    },
    {                               -- First Prop (Water Bottle)
        model = "prop_ld_flow_bottle", 
        bone = 60309,                 -- Left Hand Bone ID
        coords = vec3(0.0, 0.0, 0.0), -- X, Y, Z Offset Coordinates
        rotation = vec3(0.0, 0.0, 0.0), -- X, Y, Z Rotations
    },
    {},                               -- Second Prop (Optional, leave empty if not needed)
    function()                        -- onFinish callback
        print("Player successfully drank the water.")
        -- Logic for healing, reducing thirst, or removing the item from inventory goes here
    end,
    function()                        -- onCancel callback
        print("Drinking action was cancelled by the player!")
end)
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.0resmon.org/0resmon/frkn-resources/frkn-ui-kit-system/exports/progressbar.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
