跳到正文

Command Controls

作者:PicassoDev

A mod that gives server owners complete control over which commands players can see and use.

收藏

截图

介绍

中文介绍正在准备中,下面暂时显示原文。

Command Controls

Take full control over which commands your players can see and use!

Command Controls is a powerful server management mod that lets you configure command access based on player ranks – with seamless LuckPerms integration.


Blocks, executes and hides commands for different ranks and OP´s.



✨ Features

🔒 Complete Command Control

  • Hide commands from tab-complete – players only see what they’re allowed to use
  • Block execution of unauthorized commands
  • Rank-based permissions – configure different commands for different player groups

🔗 LuckPerms Integration

  • Automatically detects player groups from LuckPerms
  • Commands resync instantly when a player’s rank changes
  • One-click setup command: /commandcontrols luckperms-setup

🎮 Mod Compatibility

  • Works with vanilla commands AND mod commands
  • Compatible with mods using standard Minecraft permission checks (hasPermissionLevel)
  • Examples: Create, WorldEdit, Carpet Mod, Essential Commands, etc.
  • Client-side filtering for mods like Xaero’s Minimap, Litematica, etc.

⚠️ Note: Mods with their own permission systems (like Impactor) need permissions set directly in LuckPerms, not through this mod.


📦 Installation

Server (Required)

  1. Install Fabric Loader and Fabric API
  2. Drop the mod JAR into your mods folder
  3. (Recommended) Install LuckPerms for rank-based permissions

Client (Optional)

Install on clients to also hide client-side mod commands.


⚙️ Configuration

Edit config/commandcontrols/commands.json:

{
  "rank_hierarchy": ["default", "premium", "vip", "vip+", "moderator", "admin", "owner"],
  "bypass_commands": ["help"],
  "commands": {
    "all_ranks": ["help", "msg", "me", "seed", "list"],
    "vip": ["nick", "hat", "fly"],
    "moderator": ["kick", "tp", "teleport", "clear", "spectate"],
    "admin": ["ban", "give", "gamemode", "time", "weather", "effect", "summon"],
    "owner": ["stop", "op", "deop", "whitelist", "luckperms", "reload"]
  }
}

How it works:

  • rank_hierarchy – Ranks from lowest to highest (higher ranks inherit lower rank commands)
  • all_ranks – Commands everyone can use
  • [rank] – Commands for that specific rank and above

🎯 LuckPerms Setup

Automatic (Recommended)

Just run as OP:

/commandcontrols luckperms-setup

This automatically configures LuckPerms for all your ranks!

Fallback (No LuckPerms)

Without LuckPerms, the mod uses vanilla OP levels:

  • OP 4 → owner
  • OP 3 → admin
  • OP 2 → moderator
  • Everyone else → default

📋 Commands

| Command | Description |
|———|————-|
| /commandcontrols | OP Level 4 | Show help |
| /commandcontrols reload | Reload configuration |
| /commandcontrols luckperms-setup | Auto-setup LuckPerms |
| /commandcontrols status | Show your current rank and allowed commands |
| /commandcontrols resync | Synchronizes your rank permissions |

All commands require OP level 4


🔧 Technical Details

  • Overrides command permissions via reflection (similar to Player Roles)
  • Intercepts command tree packets for visibility filtering
  • Tracks command execution context for permission checks
  • Listens to LuckPerms events for instant resync on rank changes

📝 Requirements

Optional


❓ FAQ

Q: Does this work with mod commands?
A: Yes, for mods that use Minecraft’s standard hasPermissionLevel() check (most mods). Mods with custom permission systems (like Impactor, which uses Cloud Commands) need their permissions set directly in LuckPerms.

Q: Do players need the mod installed?
A: No, server-only works fine. But installing on clients hides client-side mod commands too.

Q: Commands are visible but won’t execute?
A: Make sure the command is in your config file and the player has the correct LuckPerms group.

常见问题

Command Controls 支持哪些 Minecraft 版本?

Command Controls 支持 Minecraft Java 版 1.20.1,可用的加载器:Fabric。下载时注意选择和你游戏版本一致的文件。

Command Controls 怎么安装?

先用 PCL2 或 HMCL 启动器安装对应版本的 Fabric,再把下载的 .jar 文件放进游戏目录的 mods 文件夹,重新启动游戏即可。开启了版本隔离的,mods 文件夹在 versions/版本名 下面。运行环境:客户端 / 服务端。

评论

登录后评论和评分