A RedM job based alert/ping system for Vorp
- Commands that players can utilize to alerts a job + jobgrade
- Police and Doctor preconfigured (/alertdoctor /alertpolice)
- Alerts are fully customizable
- Alert Icon
- Message
- Timinig
- Delays
- Custom Alerts are supported via the config!
- Download this repo/codebase
- Extract and place
bcc-alerts
into yourresources
folder - Add
ensure bcc-alerts
to yourserver.cfg
file - Make sure dependencies are installed/updated and ensured before this script
- Restart your server (unless you have nightly restarts)
- You die, type
/alertdoctor
into chat - All users with the roll
medic
get alerted and a 30 second map blip appears where/alertdoctor
was called
- You are getting held up! Oh no, type
/alertpolice
into chat - All users with the roll
police
get alerted and a 30 second map blip appears where/alertpolice
was called
All configurations available in /config.lua
, including custom alerts!
-- Must register alerts as soon as server starts so that when players join, they can be properly registered for the job alert
local banker_alert = exports['bcc-job-alerts']:RegisterAlert({
name = 'banker', --The name of the alert
command = nil, -- the command, this is what players will use with /
message = "Taxes need to be done!", -- Message to show to theh police
messageTime = 40000, -- Time the message will stay on screen (miliseconds)
jobs = {"banker"}, -- Jobs the alert is for
jobgrade =
{
banker = {0, 1, 2, 3 }, -- What grades the alert will effect
}
icon = "star", -- The icon the alert will use
color = 'COLOR_WHITE', -- The color of the icon / https://github.com/femga/rdr3_discoveries/tree/master/useful_info_from_rpfs/colours
texturedict = "generic_textures", --https://github.com/femga/rdr3_discoveries/tree/master/useful_info_from_rpfs/textures/menu_textures
hash = -1282792512, -- The radius blip
radius = 40.0, -- The size of the radius blip
blipTime = 60000, -- How long the blip will stay for the job (miliseconds)
blipDelay = 5000, -- Delay time before the job is notified (miliseconds)
originText = "Hang tight, the bankers have been notified", -- Text displayed to the user who enacted the command
originTime = 40000 --The time the origintext displays (miliseconds)
})
-- technically the above would register a command if command = name of command. but we set to nil, and have this command here to demonstrate programmatic usage of SendAlert(src)
RegisterCommand('TestBanker', function(src)
banker_alert:SendAlert(src)
end)
- bcc-utils
- Vorp Core