Events / Exports
All events and exports are for client
Notif
exports["tgiann-lumihud"]:Notif(text, texttype, time)
text
string
Notif message
texttype
string
primary | error | success
time
int
Notif time
example
exports["tgiann-lumihud"]:Notif("Test Message 1", "primary", 2500)
exports["tgiann-lumihud"]:Notif("Test Message 2", "error", 3500)
exports["tgiann-lumihud"]:Notif("Test Message 3", "success", 4500)
Progress
You can use it with either cb or return
local actions = {
name = "p_1", -- String > Uniq Name
duration = 2500, -- Int > Duration Time
label = "Eating...", -- String > Text to display on the progress bar
useWhileDead = useWhileDead, -- Boolen | null > Can be used while dead
canCancel = canCancel, -- Boolen | null > The player can cancel it
controlDisables = { -- Table
car = false, -- Boolen | null > Blocks everything related to vehicles
move = false, -- Boolen | null > Prevents the character from moving
combat = true, -- Boolen | null > Prevents punching, aiming, shooting, etc.
mouse = false, -- Boolen | null > Prevents mouse movement, disabling camera rotation
disableRun = true, -- Boolen | null > The player can only walk, but cannot run
},
animation = { -- Table > Play animation
animDict = "veh@van@ds@base", -- String | null > Animation Dictionary
anim = "hotwire", -- String | null > Animation name
flags = "16", -- String | null > Animation flag
},
prop = { -- Table > Attach prop 1 to entity
model = "tablet_01" -- String | number | null > Prop model or hash,
bone = 2108, -- Int | null > Bone ID
coords = { x = 0.0, y = 0.0, z = 0.0 }, -- Table | null > Axis offset from the center of the entity
rotation = { x = 0.0, y = 0.0, z = 0.0 }, -- Table | null > Axis rotation
},
propTwo = { -- Table > Attach prop 1 to entity
model = "tablet_01" -- String | number | null > Prop model or hash,
bone = 2108, -- Int | null > Bone ID
coords = { x = 0.0, y = 0.0, z = 0.0 }, -- Table | null > Axis offset from the center of the entity
rotation = { x = 0.0, y = 0.0, z = 0.0 }, -- Table | null > Axis rotation
}
}
-- CB Method
exports["tgiann-lumihud"]:Progress(actions, function(canceled)
print(canceled)
end)
-- Return Method
local success = exports["tgiann-lumihud"]:Progress(actions)
/hud Menu
Opens the buff that opens with the /hud command
TriggerEvent("tgiann-lumihud:hudMenu")
UI Open/Close
Turns ui on and off.
TriggerEvent("tgiann-lumihud:ui", open)
Parameters :
open
boolen
turns hud on if true and off if false
AddStatusHud
Adds extra hud like food, thirst, health
If you trigger this event while hud is added, it will update hud
exports["tgiann-lumihud"]:AddStatusHud(hudName, isBig, iconName, color, value, data)
Parameters :
hudName
string
Uniq name
isBig
boolen
if true, the indicator will be large like the health or armor indicator
iconName
string
Icon name: tgiann-lumihud/ui/assets
color
string
Hex or RGB color code
value
number or int
The value in the hud indicator. In percentage
data
table
Location and button settings
Example
exports["tgiann-lumihud"]:AddStatusHud("testHud", true, "phone", "red", 15, {
normal = {
style = { left = "58vh", bottom = "2vh" },
buttons = {
move = true,
color = true,
scale = true,
customButtons = true,
},
},
car = {
style = { left = "75vh", bottom = "2.9vh" },
buttons = {
move = true,
color = true,
scale = true,
customButtons = true,
},
}
})
UpdateStatusValue
Updates the percentage of a previously added hud
exports["tgiann-lumihud"]:UpdateStatusValue(hudName, value)
Parameters :
hudName
string
Uniq name
value
number or int
The value in the hud indicator. In percentage of the hud indicator
Example
exports["tgiann-lumihud"]:UpdateStatusValue("testHud", 25)
RemoveStatusHud
Removes the previously added hud
exports["tgiann-lumihud"]:RemoveStatusHud(hudName)
Parameters :
hudName
string
Uniq name
Example
exports["tgiann-lumihud"]:RemoveStatusHud("testHud")
GetTotalKm
Returns the total tm value of the vehicle
exports["tgiann-lumihud"]:GetTotalKm(plate)
Parameters :
plate
string
Vehicle plate name
Example
local totalKm = exports["tgiann-lumihud"]:GetTotalKm("AB325CD")
Seatbelt
Returns whether the player's seat belt is fastened or not
exports["tgiann-lumihud"]:Seatbelt()
Example
local seatbelt = exports["tgiann-lumihud"]:Seatbelt()
Last updated