diff --git a/[core]/es_extended/client/functions.lua b/[core]/es_extended/client/functions.lua index ee192243..72c02fd7 100644 --- a/[core]/es_extended/client/functions.lua +++ b/[core]/es_extended/client/functions.lua @@ -68,8 +68,16 @@ function ESX.SetPlayerData(key, val) end end -function ESX.Progressbar(...) - return IsResourceFound('esx_progressbar') and exports['esx_progressbar']:Progressbar(...) +---@param message string +---@param length? number Timeout in milliseconds +---@param options? ProgressBarOptions +---@return boolean Success Whether the progress bar was successfully created or not +function ESX.Progressbar(message, length, options) + return IsResourceFound('esx_progressbar') and exports['esx_progressbar']:Progressbar(message, length, options) +end + +function ESX.CancelProgressbar() + return IsResourceFound('esx_progressbar') and exports['esx_progressbar']:CancelProgressbar() end function ESX.ShowNotification(message, notifyType, length) diff --git a/[core]/esx_progressbar/Progress.lua b/[core]/esx_progressbar/Progress.lua index fcb81898..d412f581 100644 --- a/[core]/esx_progressbar/Progress.lua +++ b/[core]/esx_progressbar/Progress.lua @@ -31,6 +31,7 @@ end ---@param message string ---@param length? number Timeout in milliseconds ---@param Options? ProgressBarOptions +---@return boolean Success local function Progressbar(message, length, Options) if CurrentProgress then return false