LegacyShell WikiLegacyShell Wiki
Back to LegacyShell
Home
Wiki
Plugins
Docs
Back to LegacyShell
Home
Wiki
Plugins
Docs
  • Plugins

    • Plugin Docs

      • Default

        • Crackshot
        • Auto Restart Notifications
        • Auto Shop Notifications
        • Burnt Block Sets
        • Christmas Event
        • DeadInternet
        • FancyGraphics
        • Health Pack Item
        • Item ToolTips
        • LegacyAdmin
        • LegacyAnalytics
        • LegacySettings
        • LegacyShellCore
        • LegacyThemes
        • LegacyWeather
        • Modern Map Blocks
        • Modern Shell Guns
        • Modern Shell Hats
        • Modern Shell Stamps
        • Minerva
        • ParkourMode
        • Player Count Notifications
        • TimeMachine
        • Vaporwave Map Blocks
        • WhatsAppTheme
        • Zaxonius Custom Guns
      • Examples

        • Modern Shell Maps
    • List of plugins

Canonical source: plugins_default/playercountnotifications/README.md - edit that file, not this page (this page is built live from it, nothing here is a tracked copy).

Player Count Notifications

Posts the current player count to a Discord webhook on a timer, tracking each day's highest public/private/total counts along the way. Game-server-only (plugins.type !== "game" skips everything else).

Setup

Creates store/playercountnotifications.json on first boot:

KeyMeaning
webhooksArray of public-facing webhook URLs (a real total, no room detail).
webhooksDevArray of dev webhook URLs - same message plus a full JSON dump of every active room (game code, mode, map, player count/limit, and player/usernames).
sendIntervalSeconds between posts. Defaults to 15 - much more frequent than Auto Shop Notifications' weekly cadence, since a player count is meant to feel close to live.
lastLast successful send timestamp, same bookkeeping role as in Persistent Storage.

Privacy note: the dev webhook message includes real usernames per active room - same caveat as LegacyAnalytics, worth being deliberate about who has access to that webhook.

Notes

If a configured webhook URL is empty, the plugin permanently stops trying to post to it for the rest of that process's lifetime (this.giveup[webhook] = true) rather than retrying every interval - fixing an empty URL in the config requires a restart to take effect, not just editing the file. Daily highs reset on a plain 24-hour timer from server start, not at actual local midnight. The source carries an honest /* todo uh ... k bye */ wishlist comment (a server-naming feature, and posting game codes to the dev webhook, among the unfinished items) documenting known rough edges the author never got back to.


This page was drafted with AI assistance and reviewed for accuracy. If something looks wrong, please open a PR or flag it.

Prev
ParkourMode
Next
TimeMachine