BossTimer-Mod

模组

· 作者 FreeSpinner09

BossTimer-Mod 是一个适用于 Fabric 的服务端 Minecraft 模组,允许管理员创建并运行可配置的倒计时计时器,通过 Boss 栏显示。在计时器结束前后,还可以设置可选的消息、触发器和命令。

0 本站下载 0 关注 更新于 9 个月前

需要前置:fabric-permissions-api

最新 2.1.1 · 1.21.11 · Fabric

一键开服(送7天)

BossTimer 是一款轻量级的服务端 Fabric 模组,允许服务器管理员创建并通过 Minecraft 的 Boss 栏显示可配置的倒计时计时器。

功能介绍

BossTimer 允许你在简单的 JSON 配置文件中定义命名计时器,并通过命令启动它们。每个计时器:

  • 在 Boss 栏中显示实时倒计时
  • 实时更新文本和进度
  • 可在计时器结束前后执行命令
  • 支持在特定剩余时间触发消息(例如,“剩余 10 秒”)
  • 自动同步给正在运行计时器时加入的玩家

为什么下载它

该模组非常适合以下场景:

  • 服务器重启警告
  • 活动倒计时
  • 定时公告
  • 任何需要玩家清晰可见计时的情况

它是完全服务端的,不需要客户端安装任何模组,并且可以与 LuckPerms 等权限系统集成。

下载前的重要信息

  • 需要 Fabric 加载器 + Fabric API
  • 仅限服务端(玩家无需安装任何东西)
  • 计时器定义在 config/bosstimer_commands.json 中
  • 出于安全考虑,配置文件重载时会取消活跃计时器

配置简单,对玩家可靠,专为实际服务器使用而设计。

示例配置

{
  "restart": {
    "duration": 60,
    "bossbar_message": "⏳ %s 秒后重启",
    "before": [
      "tellraw @a {\"text\":\"[ALERT] \",\"color\":\"red\",\"bold\":true,\"extra\":[{\"text\":\"即将进行非计划内的服务器重启。请做好相应安排。\",\"color\":\"yellow\"}]}",
      "title @a title {\"text\":\"重启即将到来!\",\"color\":\"gold\"}"
    ],
    "after": [
      "tellraw @a {\"text\":\"[ALERT] \",\"color\":\"yellow\",\"bold\":true,\"extra\":[{\"text\":\"服务器即将重启。\",\"color\":\"yellow\"}]}"
    ],
    "triggers": {
      "30": {
        "message": "⏳ 剩余 30 秒。"
      },
      "10": {
        "message": "⏰ 只剩 10 秒!"
      },
      "5": {
        "message": "⚠️ 即将重启..."
      }
    }
  },
  "scheduledrestart": {
    "duration": 300,
    "bossbar_message": "计划内重启将在 %s 秒后进行",
    "before": [
      "tellraw @a {\"text\":\"[ALERT] \",\"color\":\"red\",\"bold\":true,\"extra\":[{\"text\":\"即将进行计划内的服务器重启。请做好相应安排。\",\"color\":\"yellow\"}]}",
      "title @a title {\"text\":\"即将重启!\",\"color\":\"gold\"}"
    ],
    "after": [
      "tellraw @a {\"text\":\"[ALERT] \",\"color\":\"yellow\",\"bold\":true,\"extra\":[{\"text\":\"服务器即将重启。\",\"color\":\"yellow\"}]}"
    ],
    "triggers": {
      "180": {
        "message": "⏳ 距离重启还有 3 分钟!"
      },
      "60": {
        "message": "⚠️ 60 秒后重启!"
      },
      "10": {
        "message": "⏰ 只剩 10 秒!"
      }
    }
  },
  "reload": {
    "duration": 45,
    "bossbar_message": "? %s 秒后重载",
    "before": [
      "tellraw @a {\"text\":\"[ALERT] \",\"color\":\"red\",\"bold\":true,\"extra\":[{\"text\":\"即将进行非计划内的服务器重载。请做好相应安排。\",\"color\":\"yellow\"}]}",
      "title @a title {\"text\":\"重载即将到来!\",\"color\":\"gold\"}"
    ],
    "after": [
      "tellraw @a {\"text\":\"[ALERT] \",\"color\":\"red\",\"bold\":true,\"extra\":[{\"text\":\"服务器现在正在进行重载。\",\"color\":\"yellow\"}]}",
      "reload"
    ],
    "triggers": {
      "20": {
        "message": "⏳ 重载前剩余 20 秒。"
      },
      "10": {
        "message": "⏰ 最后 10 秒!"
      },
      "5": {
        "message": "⚠️ 即将重载..."
      }
    }
  },
  "dropparty": {
    "duration": 300,
    "bossbar_message": "? %s 秒后掉落派对开始",
    "before": [
      "tellraw @a {\"text\":\"[EVENT] \",\"color\":\"aqua\",\"bold\":true,\"extra\":[{\"text\":\"掉落派对即将在 \",\"color\":\"white\"},{\"text\":\"/warp dropparty\",\"color\":\"yellow\",\"underlined\":true},{\"text\":\" 开始。\",\"color\":\"white\"}]}",
      "title @a title {\"text\":\"? 掉落派对即将到来!\",\"color\":\"aqua\"}"
    ],
    "after": [
      "tellraw @a {\"text\":\"[EVENT] \",\"color\":\"aqua\",\"bold\":true,\"extra\":[{\"text\":\"掉落派对已在 \",\"color\":\"white\"},{\"text\":\"/warp dropparty\",\"color\":\"yellow\",\"underlined\":true},{\"text\":\" 开始。\",\"color\":\"white\"}]}",
      "title @a title {\"text\":\"? 掉落派对已开始!\",\"color\":\"aqua\"}"
    ],
    "triggers": {
      "180": {
        "message": "⏳ 距离 /warp dropparty 的掉落派对还有 3 分钟!"
      },
      "60": {
        "message": "⏰ 剩余 1 分钟!准备前往 /warp dropparty 获取掉落物品!"
      },
      "10": {
        "message": "? 掉落派对随时开始!请使用 /warp dropparty!"
      }
    }
  }
}

你是这个资源的作者?登录后可认领此资源。

评论 0

0.0
暂无评分
5 星
0
4 星
0
3 星
0
2 星
0
1 星
0
我的评分

登录后参与评分

还没有评论,来抢沙发吧

评论配图

相似资源