Diamond Luck: Anti-Cheat Datapack for Minecraft Servers

Diamond Luck: A Powerful Datapack for Detecting Suspicious Mining in Minecraft Running a multiplayer survival server comes with its fair share of challenges, and one of the most persistent headaches for administrators is catching players who use unfair advantages like XRay or automated mining bot...

Download 1.18.x for Minecraft 1.18.1, 1.18-Snapshot

Original name: 1.18.x

Minecraft: 1.18-Snapshot, 1.18.1

FileVersionLoaderSize
1.18.x_v1.0 DiamondLuck.zip1.18-Snapshot—16 КБDownload
1.18.x_v1.0.1 DiamondLuck.zip1.18.1—16 КБDownload
DiamondLuck 1.1.zip1.18.1—17 КБDownload

Diamond Luck: A Powerful Datapack for Detecting Suspicious Mining in Minecraft

Running a multiplayer survival server comes with its fair share of challenges, and one of the most persistent headaches for administrators is catching players who use unfair advantages like XRay or automated mining bots. Enter Diamond Luck, a clever datapack that transforms how you monitor player behavior by calculating a unique luck percentage based on their mining habits. Whether you manage a small community or a bustling network, this tool gives moderators a data-driven way to spot potential cheaters before they ruin the experience for everyone else.

What Exactly Is Diamond Luck?

Diamond Luck is an adaptation of the well-known TopLuck plugin, redesigned to work seamlessly as a datapack. Its core function is simple yet effective: it tracks every block of stone and every diamond ore a player mines, then computes a luck rate. A player who mines an unusually high number of diamonds compared to the amount of stone broken will show a suspiciously high percentage. This pattern often indicates the use of XRay texture packs or mods that let players see ores through walls, or even automated tools like Baritone that tunnel directly to valuable resources.

Moderators can use this percentage as a red flag. Instead of blindly accusing someone, they can observe the player’s mining sessions, watch their pathing, and gather solid evidence before taking action. It adds a layer of transparency and fairness to server moderation, shifting away from guesswork and toward actual statistics.

Why a Datapack Instead of a Plugin?

One of the standout benefits of Diamond Luck is its format. Because it runs as a datapack, it remains compatible with virtually every server software out there — Spigot, Paper, Bukkit, Sponge, Forge, Fabric, and even pure Vanilla. You do not have to worry about plugin conflicts or version-specific builds. The datapack hooks directly into Minecraft’s vanilla command system, making it lightweight and easy to update when a new game version drops.

That said, be aware that some server setups include mods or plugins that alter vanilla command behavior. These can occasionally interfere with Diamond Luck’s functionality, so it is wise to test the datapack in a staging environment before deploying it to a live server. For administrators who also enjoy enhancing their single-player or modded worlds, the foxygame.net launcher provides a convenient, flexible, and modern way to download and manage mods directly from its menu, streamlining the entire setup process without digging through endless forum threads.

Setting Up Diamond Luck

Installation is refreshingly straightforward. Simply download the datapack ZIP file and place it into the datapacks folder inside your world directory. After a quick server restart or a /reload, the datapack will be active. No complex configuration files to edit, no permissions to wrestle with — just drop it in and you are ready to go.

To access the graphical user interface, any player with the appropriate tags can type /trigger DiamondLuck. The GUI displays a list of online players along with their calculated luck percentages, making it easy to scan for anomalies at a glance. The interface is clean and intuitive, with a simple close button to dismiss it when you are done.

Granting Access and Using the GUI

Diamond Luck uses a tag-based permission system. To give a staff member access, you need to assign two tags:

  • dl_OP — grants basic operator-level access to the datapack’s features.
  • dl_Admin — provides full administrative privileges, including the ability to teleport to players directly from the GUI when combined with the optional AdminCam datapack.

Assign these tags with simple commands:

/tag USERNAME add dl_OP
/tag USERNAME add dl_Admin

Once tagged, staff members can open the GUI, review luck percentages, and decide which players warrant closer observation.

Pairing Diamond Luck with AdminCam for Instant Teleportation

For an even more powerful moderation workflow, you can install the optional AdminCam datapack alongside Diamond Luck. When both are active, clicking on a player’s head inside the Diamond Luck GUI instantly teleports you to that player’s location. You appear in spectator mode, completely invisible, and can watch their mining patterns in real time. When you are finished, a simple command returns you to your original position and restores your previous gamemode. This integration turns a statistical alert into a hands-on investigation tool without disrupting the player’s experience or tipping them off.

To set up AdminCam, just download its datapack version and place it in the same datapacks folder. No extra configuration is required; Diamond Luck automatically detects its presence and enables the teleport feature.

Important: Uninstalling Properly

Diamond Luck creates a number of scoreboards behind the scenes to track player statistics. Simply deleting the datapack files without cleanup can leave behind lingering data that might cause issues. Before removal, run the command /function dl:commands/uninstall. This will clear all associated scoreboards and prepare the world for a clean removal. After running the uninstall function, you can safely delete the datapack files. Crucially, do not use /reload or restart the server between running the uninstall command and deleting the files; doing so can cause the cleanup to fail. If you also have AdminCam installed, repeat the same uninstall process for that datapack.

Why Every Server Administrator Should Consider Diamond Luck

Cheating in multiplayer Minecraft can quickly erode trust and drive away honest players. Diamond Luck gives you a non-invasive, data-driven method to identify suspicious behavior without relying on anecdotal reports. The luck percentage acts as an early warning system, allowing your moderation team to focus their attention where it is most needed. Because it is a datapack, it works across server versions and software, and its integration with AdminCam makes the leap from numbers to observation seamless.

In a landscape where server tools are often bloated or version-locked, Diamond Luck stands out as a lightweight, practical solution. Whether you run a tight-knit survival world or a large public server, adding this datapack to your moderation toolkit can help maintain a fair and enjoyable environment for everyone.