Whitelist Script - Updated & Optimized

:shield: BeamMP Whitelist Plugin - Updated Version

A simple, reliable, and optimized whitelist plugin for BeamMP server


:sparkles: Features

  • :white_check_mark: Uses modern onPlayerAuth event for better stability
  • :white_check_mark: Simple JSON-based whitelist configuration
  • :white_check_mark: Clean and readable code structure
  • :white_check_mark: Detailed error logging for easy debugging

:inbox_tray: Installation

  1. Download the plugin from GitHub
  2. Extract to Resources/Server/whitelist/
  3. Edit whitelist.json to add your allowed players
  4. Restart your server

:open_file_folder: Download

GitHub Repository:
:link: https://github.com/Alshemeri/-BeamMP-Server-Whitelist-Script/


:gear: Configuration

Simply edit whitelist.json:

[
    "PlayerName1",
    "PlayerName2",
    "AnotherPlayer"
]

Note: Usernames are case-sensitive


:counterclockwise_arrows_button: What’s New?

This is an updated version of the original whitelist script with the following improvements:

  • Migrated from onPlayerConnecting to onPlayerAuth
  • Fixed file path handling
  • Simplified JSON structure (no nested wrapper)
  • Enhanced error handling and validation
  • Better logging for troubleshooting
  • Optimized whitelist checking algorithm

:clipboard: Credits

Original script by Race-Life


:scroll: License

Released under the Unlicense - free for everyone to use and modify


Hello,

Thank you for helping to contribute to the BeamMP Community!

Might I ask why you opt to use usernames rather than the account identifiers which are a better and more reliable source of truth for identifying a player?

You’re absolutely right identifiers are a more reliable and stable way to authenticate players
The original script I updated was designed around usernames, so I kept the same logic for compatibility and simplicity, especially for server owners who prefer editing a simple whitelist.json file.

However, I do plan to add support for identifiers (or an optional mode to use both identifiers and usernames) in a future update.
Thanks for pointing it out definitely a good improvement to include