rollCommand 图标

rollCommand

作者:rebot | 分类:模组

价格:0 墨喵币 下载量:0 点赞:0 版本 0.0.1
本资源为搬运资源,原资源地址: https://modrinth.com/mod/rollcommand
资源信息

Minecraft 版本: 1.2.1 1.2.2 1.2.3 1.2.4 1.2.5 1.13 1.13.1 1.13.2 1.14 1.14.1 1.14.2 1.14.3 1.14.4 1.15 1.15.1 1.15.2 1.16 1.16.1 1.16.2 1.16.3 1.16.4 1.16.5 1.17 1.17.1 1.18 1.18.1 1.18.2 1.19 1.19.1 1.19.2 1.19.3 1.19.4 1.20 1.20.1 1.20.2 1.20.3 1.20.4 1.20.5 1.20.6 1.21 1.21.1 1.21.2 1.21.3 1.21.4

平台: bukkit paper purpur spigot

标签: economy game-mechanics minigame

资源介绍

RollCommand Plugin

RollCommand is a Minecraft plugin that allows server administrators to create and manage lists of commands to be executed at random. With this plugin, you can configure multiple command lists—each with its own cooldown and weighted command selection—to add fun and variety to your server.

Features

  • Random Command Execution:
    Execute a random command from the currently selected list using the /roll command.

  • Multiple Command Lists:
    Define several command lists with unique cooldown periods and command weights.

  • Weighted Commands:
    Assign weights to commands to influence the likelihood of selection.

  • In-Game Management:
    Use the /rlist command to display available command lists and select an active one.

  • Admin Testing:
    Execute a test command (/rtest) to run a random command without affecting cooldowns (Admin only).

Commands

  • /roll (alias: /r)

    • Executes a random command from the active command list.
    • Permission: rollCommand.use
  • /rlist

    • When provided with a list name, sets it as the active command list.
    • Without arguments, displays available command lists and the currently active one.
    • Permission: rollCommand.admin
  • /rtest

    • Executes a random command without enforcing the cooldown period.
    • Permission: rollCommand.admin

Configuration

The plugin configuration is defined in src/main/resources/config.yml. Below is an example configuration:

chosenList: exampleList

commandLists:
  diamondList:
    cooldown: 120
    commands:
    - command: "/give %p diamond 64"
      weight: 1
    - command: "/give %p diamond_block 32"
      weight: 2
    - command: "/effect give %p haste 300 2"
      weight: 3
  exampleList:
    cooldown: 60
    commands:
    - command: "/give %p diamond 1"
      weight: 1
    - command: "/say Hello, %p!"
      weight: 2
  funList:
    cooldown: 30
    commands:
    - command: "/effect give %p jump_boost 30 3"
      weight: 3
    - command: "/effect give %p speed 30 2"
      weight: 2
    - command: "/give %p cookie 1"
      weight: 1

Configuration Details:

  • chosenList:
    Specifies the active command list to be used by the /roll and /rtest commands.

  • commandLists:
    Under this section, each command list (e.g., exampleList, diamondList, funList) can have its own cooldown (in seconds) and a list of commands.
    Each command is defined along with a weight that influences its random selection probability.
    %p in a command will be replaced by the player's name.

Plugin Manifest

The plugin details are stored in plugin.yml. This file defines:

  • The plugin name and description.
  • The main class, which is link.kmaba.rollCommand.App.
  • Commands (/roll, /rlist, and /rtest) along with their usage instructions.
  • Required permissions:
    • rollCommand.use (default: true)
    • rollCommand.admin (default: op)

Quick Start

  1. Deploy the Plugin:
    Place the compiled jar (rollCommand-0.0.1.jar) into your server's plugins folder.

  2. Configure:
    Adjust the settings in config.yml as needed.

  3. Start the Server:
    Launch or reload your server.

  4. Use the Commands:

    • Execute /roll / /r to perform a random command from the active list.
    • Use /rlist to view available command lists or change the active list.
    • Test commands with /rtest (requires admin permission).
下载太慢?试试 墨喵加速站,支持 Modrinth 和外网直链高速下载! 用的人越多,下载的越快!
下载与版本
评论(0)
登录 后发表评论。

暂无评论,抢个沙发吧~

举报此资源

请登录后举报

🔥 相关推荐
Xyndra's Crates

价格:0 墨喵币
下载量:0

查看详情
Kokushibo katana from anime Demin slayer

价格:0 墨喵币
下载量:0

查看详情
totem_anime_pak

价格:0 墨喵币
下载量:0

查看详情
Moon Spire

价格:0 墨喵币
下载量:0

查看详情