Examples

Config

Config = {}

Config.CheckVersion = true -- do you wanna stay up to date? will print in server console

Config.MenuType = 'ox_libs'


Config.jobsAuth = {
    ['police'] = true,
    ['bcso'] = true,
}

Config.BountyJobs = {
      ['bondsman'] = true,
      ['police'] = true
}

Config.NotificationType = { --['okokNotify' / 'mythic' / 'esx' / 'chat' / 'custom' ]
    client = 'okokNotify', 
    server = 'okokNotify'
}

Notifications

function Cnotify(noty_type, message)
    if noty_type and message then
        if Config.NotificationType.client == 'esx' then
            ESX.ShowNotification(message)
        elseif Config.NotificationType.client == 'okokNotify' then
            if noty_type == 1 then
                exports['okokNotify']:Alert("Warrants", message, 10000, 'success')
            elseif noty_type == 2 then
                exports['okokNotify']:Alert("Warrants", message, 10000, 'info')
            elseif noty_type == 3 then
                exports['okokNotify']:Alert("Warrants", message, 10000, 'error')
            end
        elseif Config.NotificationType.client == 'mythic' then
            if noty_type == 1 then
                exports['mythic_notify']:SendAlert('success', message, { ['background-color'] = '#ffffff', ['color'] = '#000000' })
            elseif noty_type == 2 then
                exports['mythic_notify']:SendAlert('inform', message, { ['background-color'] = '#ffffff', ['color'] = '#000000' })
            elseif noty_type == 3 then
                exports['mythic_notify']:SendAlert('error', message, { ['background-color'] = '#ffffff', ['color'] = '#000000' })
            end
        elseif Config.NotificationType.client == 'chat' then
            TriggerEvent('chatMessage', message)        
        elseif Config.NotificationType.client == 'other' then
            --add your own notification.       
        end
    end
end

Last updated