JustScripts
  • Welcome to JustScripts Documentation
  • JustCarWash
    • Installation
    • Config Setup
  • JustHud
    • Configuration
    • Features
    • Chat
    • Placeholders
    • Elements
    • Custom Elements
    • Exports
  • JustHud(Old)
    • Installation
    • Config Setup
    • Events
  • JustTrucker
    • Installation
    • Config Setup
  • JustSecurity
    • Installation
  • JustDrugs
    • Installation
  • JustFarmer
    • Installation
  • JustCases
    • Configuration
    • Exports
    • Tebex integration
  • JustBank
    • Configuration
    • Exports
    • Society Accounts
  • JustDataSync
  • JustFishing
  • JustNotify
    • Exports
Powered by GitBook
On this page
  • Client-side Exports
  • ToggleHud
  • Notify
  • AddProgress
  • ClearProgress
  • GetSeatbeltStatus
  • SetSeatbeltStatus
  • IsSpeedLimited
  • GetSettingValue
  • GetColor
  • AddBroadcast
  1. JustHud

Exports

Client-side Exports

ToggleHud

Hide or show the HUD

-- toggle: boolean
exports.Justhud:ToggleHud(toggle)

Notify

Send a notification to player hud

-- title: string
-- content: string
-- type: string - success,warning,error,info,question
-- time: number - showing time in ms
exports.Justhud:Notify(title,content,type)

AddProgress

Shows progress bar on user hud. see here for icon docs.

-- text: string - Progress bar description
-- icon: string - Progress bar icon
-- time: number - Progress bar showing time in ms
-- options: tabel - extra objects
exports.JustHud:AddProgress(text,icon,time, options)

exports.JustHud:AddProgress("Eating","internal:BurgerIcon", 5000, {
    freeze = true, -- freeze player during the progress
    onFinish = function ()
    end
})

ClearProgress

Stops the currently running progress

exports.JustHud:ClearProgress()

GetSeatbeltStatus

Determining whether player has seatbelt on

-- return: boolean
exports.JustHud:GetSeatbeltStatus()

SetSeatbeltStatus

Changing player seatbelt status

-- toggle: boolean
exports.JustHud:SetSeatbeltStatus(toggle)

IsSpeedLimited

Determining whether player vehicle speed is limited

-- return: boolean
exports.JustHud:IsSpeedLimited()

GetSettingValue

Get the value of custom settings (Config.Settings.Options.custom)

-- id: string - setting id
-- return: mixed
exports.JustHud:GetSettingValue(id)

GetColor

Get the color changed in settings (default if unchanged)

-- id: string - color id (primary,secondary,success,danger,warning,info)
-- return: string
exports.JustHud:GetColor(id)

AddBroadcast

Sends a broadcast to chat for all players

-- title: string
-- icon: string
-- content: string
-- color: string (color ID or hexcolor)
exports.JustHud:AddBroadcast(title, icon, content, color)
PreviousCustom ElementsNextJustHud(Old)

Last updated 2 months ago