Mod

Better Whitelist

Quick rating

Better Whitelist

No reviews yet

A configurable whitelist system for Minecraft

Mod Loaders
Fabric
Minecraft

Community voices

Reviews

Filter by exact patch versions
Loading exact versions…
Match includes

Click once to include, again to exclude, again to clear

Rating Any
Any 0.5 1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0
Min
Max
Play Status
Reviews
Time Played
hrs+
Verified developers only
Has developer response
List view
Grid view
Compact view
Sort by
Date
Rating
Helpful
Unhelpful
Edited
Sort ascending
Delete this review?

This removes your review from the project. You can write a new review after.

Review submitted for moderation

Your updated review is now pending. It has been sent to moderators, who will check that it meets our guidelines before it appears publicly.

No reviews yet. Be the first to review this project!

Get it on

Available Platforms

Compatibility

Supported Environments

Dev Environment
Client Required
Server Required

About

Project Details

Type
Mod
License
MIT License
Latest Version
26.1.0
Authors

For authors

Embed Badge

If you're the author of this project, you can embed a live badge anywhere that supports HTML or Markdown. It updates automatically whenever ratings change.

Custom banner text
ModDex rating badge preview

Use HTML for any page that supports it, or Markdown for README files and Markdown-based descriptions.

Identifiers

Platform IDs

Modrinth ID

Resources

External Links

Source Issues Wiki Discord

About

Description

Better-Whitelist provides a basic whitelist system for your server that you can adapt to your use case.

The mod is required both on the server and any clients connecting to the server.

The whitelist is configured using μScript, but you don't have to be good at programming to use this mod.

A config file with some additional details will be created when you first start your server with the mod.

A simple config for Better-Whitelist could look as follows (please note that you'd probably have to add exceptions for client-side mods with optional server-side components when using this):

// convert a mod to a simpler representation to save bandwidth
simplify = { mod -> { id = mod.id, version = mod.version } }

// all non-serverside mods present on the server
sharedMods = mods::values()
  ::filter({ v -> v.environment != 'server' & v.id != 'java' })
  ::map(simplify)

// ensure the client has the correct version of every non-serverside mod on the server
clientMissing = challenge({ arg ->
  arg::filter({ v -> !mods::values()::anyMatch({ m -> v.id == m.id & v.version == m.version }) })
}, sharedMods)
assert(clientMissing::isEmpty(), 'You lack required mods: ' || clientMissing)

// ensure the client has no additional mods that would be required on the server
clientAdditional = challenge({ arg, fn ->
  clientSideMods = mods::values()::filter({ v -> v.environment != 'client' & v.id != 'java' })
  clientSideMods::filter({ v -> !arg::anyMatch({ m -> v.id == m.id & v.version == m.version }) })::map(fn)
}, sharedMods, simplify)
assert(clientAdditional::isEmpty(), 'You have unsupported mods: ' || clientAdditional)

// filter resource packs for X-Ray packs
bannedWords = listOf('xray', 'x-ray', 'cheat')
assert(!challenge({ ->
  resourcePacks::map({ pack -> pack.name || ' ' || pack.displayName || ' ' || pack.description })
})::anyMatch({ v -> bannedWords::anyMatch({ word -> v::toLower()::contains(word) }) }), "Please don't cheat, " || user.name)

The following things are available to your scripts:

  • All methods from the μScript standard library (including date/time, meaning you can temporarily whitelist or blacklist users or create countdowns)
  • resourcePacks (client only): a list of resource packs, each of which has a name, displayName and description
  • println('message') (both): a function for debugging
  • mods (both): a list of loaded mods with the same fields as the result of mod()
  • mod('id') (both): information about a specific mod (or null): id, name, description, authors (list of strings), contributors (list of strings), version, environment (either client, server or *), license, contact (same as FMJ), depends (list of strings)
  • assert(bool) (server): assert that something is true and kick the player if it's not (optionally, add a message as the second parameter)
  • challenge({->closure}, additional arguments...) (server): send a closure to the client to be executed there. The arguments may contain other closures.
  • user (server): information about the user trying to log in, namely their id and name
Suggestions and Support

Screenshots

Gallery

This project has no gallery images yet.

Versions

Files

Relations

Project Relations

More like this

Similar Mods

Suggestions use data such as tags, dependencies, dependents, descriptions, titles, and more to rank how much they overlap with this mod.

On ModDex

Community snapshot

0
Reviews
0
Followers
0
In stacks

By the numbers

Statistics

~2,000
Downloads
Last Updated
CurseForge
Created
Last synced
When ModDex last fetched and imported data for this project from CurseForge or Modrinth. High-traffic and active projects are checked more often.
Next pipeline sync