▶️ ЗАБЕРИ СВОИ 8 ПОДАРКОВ 🎁 ПРИ СОЗДАНИИ СВОЕГО МАЙНКРАФТ СЕРВЕРА
Моды/CustomCommands
CustomCommands

CustomCommands

A powerful custom commands plugin with subcommands, console command execution, and clickable links. Create unlimited custom commands with variable replacement, permissions, and modern text formatting for your Paper server.

1.0K
5
Все версииCustomCommands 1.0.2

CustomCommands 1.0.2

Release3 мес. назад

Список изменений

Custom Commands Major Update - Arguments, Nesting & Player Validation

🎮 New Features

We've added three powerful features that make custom commands more flexible and user-friendly!

✨ Feature 1: Arguments System

Dynamic Command Arguments

  • Add arguments to any custom command or subcommand
  • Use {args} variable in messages and commands to access arguments
  • Configure whitelists, validation, and required arguments
  • Support for arguments with spaces

Configuration:

arguments:
  whitelist: ["hello", "goodbye"]  # Allowed arguments
  whitelist-only: true              # Only allow whitelisted args
  no-arguments: true                 # Allow command without args
  invalid-message: "&cInvalid arguments!"

Example:

say:
  arguments:
    whitelist: ["hello", "goodbye", "help"]
    whitelist-only: true
  commands:
    - "say {player}: {args}"  # Use {args} in commands

✨ Feature 2: Nested Subcommands

Unlimited Command Nesting

  • Subcommands can now have their own subcommands (unlimited depth!)
  • Perfect for organizing complex command structures
  • Each level has its own permissions and messages

Example:

admin:
  subcommands:
    player:
      subcommands:  # Nested subcommands!
        kick:
          commands:
            - "kick {args} Kicked by admin"
        ban:
          commands:
            - "ban {args} Banned by admin"

Usage:

  • /admin player kick Steve - Kicks a player
  • /admin player ban Steve - Bans a player
  • /admin server restart - Restarts the server

✨ Feature 3: Player Arguments (player-args)

Automatic Player Validation

  • Mark specific arguments as player names using player-args: [0]
  • Automatic validation ensures players exist and are online
  • Smart tab-completion shows all online players
  • Clear error messages for invalid players

Configuration:

kick:
  arguments:
    player-args: [0]  # First argument = player name
    no-arguments: false
  commands:
    - "kick {args} Kicked by {player}"

Features:

  • ✅ Prevents typos and invalid player names
  • ✅ Faster command usage with tab-completion
  • ✅ Works with nested subcommands
  • ✅ Multiple player arguments supported: player-args: [0, 1]

📝 Combined Example

All three features work together perfectly:

admin:
  permission: "customcommands.admin"
  subcommands:
    player:
      permission: "customcommands.admin.player"
      subcommands:  # Nested subcommands
        kick:
          permission: "customcommands.admin.player.kick"
          arguments:
            player-args: [0]  # Player validation
            no-arguments: false
          commands:
            - "kick {args} Kicked by {player}"

Usage: /admin player kick Steve

  • Uses nested subcommands (adminplayerkick)
  • Validates that Steve is a valid online player
  • Executes the kick command with the player name

🎯 Benefits

Arguments System:

  • ✅ Flexible command input
  • ✅ Input validation
  • ✅ Whitelist support
  • ✅ Use arguments in messages and commands

Nested Subcommands:

  • ✅ Better command organization
  • ✅ Unlimited nesting depth
  • ✅ Individual permissions per level
  • ✅ Clean command structure

Player Arguments:

  • ✅ Automatic player validation
  • ✅ Tab-completion for players
  • ✅ Error prevention
  • ✅ Better user experience

Full Changelog:

  • Added arguments system with whitelist and validation support
  • Implemented nested subcommands (unlimited depth)
  • Added player-args configuration for automatic player name validation
  • Implemented automatic tab-completion for player arguments
  • Added player-specific error messages
  • Fixed spam issue with tellraw commands
  • Improved argument handling and validation
  • Enhanced tab-completion system

Файлы

Custom-Commands-1.0.2.jar(73.77 KiB)
Основной
Скачать

Метаданные

Канал релиза

Release

Номер версии

1.0.2

Загрузчики

Paper
Purpur

Версии игры

1.19.3–1.21.10

Загрузок

12

Дата публикации

3 мес. назад

Загрузил

ID версии

Главная