π’ Broadcast system β every detail
The composer
Hub β Events β Broadcast. A message goes to every online player; how it looks follows the notification toggle (mod UI or the ZYAD toast). Every send is validated server-side.
| Control | Behaviour |
|---|---|
| Text | Free text, may contain the {t} placeholder (see countdown). |
| Style | Info / Warning / Event β sets the message heading. |
| Mode | Click through: Once (immediately) Β· Countdown (N messages on an interval, {t} = time left, e.g. βRestart in {t}β) Β· Repeat (same message N times). |
| Count / interval | For countdown/repeat; capped at 1β20 messages and 5β3600 s. |
| Send | First message goes out immediately, the rest is scheduled server-side. |
Templates
Reusable messages (name / text / style), stored in Broadcast/broadcasts.json.
Sensible defaults are created on the first server start (restart / event / rules / Discord).
| Control | Behaviour |
|---|---|
| Use | Loads the template into the composer, where you can still adjust it before sending. |
| X | Deletes the row. |
| Save | Saves the whole list; the server sanitises it (trims, clamps, drops empty rows). |
Rotation (automatic sending)
| Control | Behaviour |
|---|---|
| Master switch | Rotation on/off (default: off). |
| Template | Click-through button cycling all templates. |
| Mode | Interval (minutes) β time of day (HH:MM, local server time). |
| Server time | Shown live in the editor β no guessing time zones. |
| Active / X | Toggle or delete each row individually. |
| Save | Takes effect live β the scheduler re-arms immediately. |
Scheduler details
- Interval entries fire for the first time one interval after boot/save β no message spam at server start.
{t}is stripped in interval mode. - Time of day without
{t}: exactly one message at that time. - Time of day with
{t}: automatic advance warnings 30/15/10/5/2/1 minutes before, with{t}= time left (β5 minβ). No zero message β the last warning is at 1 minute. - Timing is accurate to the second, each moment fires at most once per day (reset at midnight), moments already past at boot are skipped, and a ~2 minute catch-up window covers restarts that land right on one.
The restart trick: a single time-of-day entry with a
{t} template
(βServer restart in {t}!β) replaces six manual announcements β the whole warning ladder runs
by itself.Design tips
- Put rules and Discord reminders on long intervals (45β90 min) β rotating messages lose their value once they become wallpaper.
- Use the styles consistently (Info = neutral, Warning = action needed, Event = get over there!) β players learn to read the heading and colour at a glance.