🎮Client Side
Exports List
exports['ug-dispatch']:SendDispatch(code: number)
exports['ug-dispatch']:SendCustomDispatch(customCode: table)
Send Dispatch
This export is used to start the process of triggering a code.
Usage:
exports['ug-dispatch']:SendDispatch(code: number)
Example:
RegisterCommand('sendCode', function (source, args)
local code = tonumber(args[1]) -- The code in number.
exports['ug-dispatch']:SendDispatch(code)
end, false)
Returns:
None
Send Custom Dispatch
This export is used to start the process of sending a custom code that doesn't exist (Can be used to use in the SOS calls for example). The custom code must be a code that requires having all the code settings (not required having the default key and the code content). Refer to this documentation to know how to use.
Usage:
exports['ug-dispatch']:SendCustomDispatch(customCode: table)
Example:
RegisterNetEvent('myUgDevScript:SendSOS', function (message)
local codeData = {
Name = 'SOS Call',
Description = message,
Type = 'code',
Color = '#000000',
Jobs = {
'police',
'ambulance'
},
Sound = {
Enable = true,
Name = 'code.ogg',
Volume = 0.05
}
}
exports['ug-dispatch']:SendCustomDispatch(codeData)
end)
Returns:
None
Last updated
Was this helpful?