Custom Teams
插件由 imNikos 制作。
一款适用于 Paper/Bukkit 的插件,用于运行由管理员控制的 PvP 事件——支持 自由混战 (Free-For-All) 或 4队对战 模式。包含基于 GUI 的设置界面、自定义装备包、智能出生点生成以及每位玩家独立的装备包保存功能。
功能特性
- 两种事件模式
- 自由混战 (FFA): 不限人数,每位玩家独立作战并显示白色名称标签。获胜者的个人名字会被播报,而非队伍名称。
- 组队模式: 固定 4 支队伍——红队、蓝队、绿队、黄队 ——使用浅色变体作为名称标签、Tab 列表和聊天前缀的颜色。
- 灵活的出生点系统
- 组队模式: 使用世界内的快捷栏工具为每支队伍设置多个出生点。
- FFA: 可选择为每位玩家设置一个专属出生点,或者设置一个中心点,该点会根据玩家数量自动将玩家均匀散布在周围一定半径内。
- 所有自动生成的出生点在使用前都会检查地面是否安全且不会导致窒息(非阻塞)。
- 全局事件装备包编辑器 — 构建一个共享装备包(包括护甲、副手物品、药水效果和 27 个背包格子),所有参与者在比赛开始时都会获得此装备包。
- 个人装备包保存 — 每位玩家可以保存和加载最多 3 套自己的个人装备包,这与事件全局装备包相互独立。
- 比赛安全窗口
- 比赛开始时有 5 秒无敌时间(且无法造成伤害),以防止有人在加载进入时被偷袭。
- 胜利者(们)在庆祝期间享有 10 秒无敌时间。
- 可配置开关 — 初始游戏模式、击杀回血和自然恢复,均可通过管理员 GUI 切换。
- 自动观战 — 死亡的玩家将被移至观战模式,可以选择以观战身份重新加入或完全退出事件。
- 持久化数据 — 装备包和出生点存储在
kits.yml 中,服务器重启后依然存在。
命令
| 命令 |
描述 |
权限 |
/ct |
打开管理员控制面板(队伍、出生点、装备包创建器、开关、开始/结束事件)。 |
customteams.admin |
/ct leave |
离开当前正在运行的事件,并恢复你进入事件前的背包和位置。 |
无 |
/ct kits |
打开你的个人“我的装备包”菜单(保存/加载最多 3 套个人装备包)。 |
无 |
输入 /ct 后按 Tab 键会自动补全 leave 和 kits。
权限
| 权限 |
描述 |
customteams.admin |
访问管理员面板:队伍/名单管理、出生点设置、装备包创建以及开始/结束事件。 |
任何玩家(无论是否拥有管理员权限)都可以使用 /ct leave 和 /ct kits。
管理员 GUI 指南
运行 /ct 打开 Custom Teams Settings:
-
Teams(队伍) → 选择下一场事件的填充方式:
- Free-For-All (FFA) → 打开分页玩家选择器。点击玩家以切换其选中状态,然后点击 Confirm & Set FFA Roster 确认锁定名单。
- Manual Teams(手动组队) → 选择一种颜色,然后点击玩家将其分配/取消分配到该队伍。
-
Spawns(出生点) → 选择要配置的出生点系统:
-
FFA Spawns → 要求已设置好 FFA 名单(以便插件知道需要多少个出生点)。然后选择:
- Exact Spawn Points(精确出生点) — 你会获得与参与者数量相同的白羊毛;将每一块放置在你希望玩家出生的位置。
- Radius Spawn Point(半径出生点) — 你会获得一块白羊毛;只需放置一次作为中心点,插件会根据玩家数量自动将玩家均匀散布在周围。
-
Team Spawns(队伍出生点) → 进入世界内编辑模式,快捷栏布局如下:
| 槽位 |
物品 |
| 1 |
红色出生点(放置以添加红色出生点) |
| 2 |
蓝色出生点 |
| 3 |
绿色出生点 |
| 4 |
黄色出生点 |
| 5 |
红色出生点重置(右键点击仅清除红色的出生点) |
| 6 |
蓝色出生点重置 |
| 7 |
绿色出生点重置 |
| 8 |
黄色出生点重置 |
| 9 |
保存并退出 |
在主背包中,你还会找到 Cancel(丢弃所有更改)和 Reset All(清除所有队伍的出生点)。直到你点击 Save and Exit 之前,任何更改都不会写入磁盘。
-
Kit Creator(装备包创建器) → 构建全局事件装备包:将物品拖放到护甲/副手槽位和药水效果槽位,然后点击绿宝石块进行保存。
-
Gamemode / Natural Regen / Health on Kill toggles(游戏模式 / 自然恢复 / 击杀回血 开关) → 点击以翻转每个设置;更改会立即保存到 config.yml。
-
Start Event / Force End Event(开始事件 / 强制结束事件) → 开始 5 秒倒计时(所有排队参与者可见标题提示)或立即结束正在进行的事件。
个人装备包 (/ct kits)
每位玩家拥有 3 个个人预设栏位,与管理员的主预设独立:
- 左键点击栏位可将保存的预设加载到当前物品栏中。
- 右键点击栏位可将当前物品栏内容保存至该栏位。
这些数据按玩家存储,并在会话间持久保留。
配置 (config.yml)
settings:
gamemode-on-start: SURVIVAL # 或 ADVENTURE
health-on-kill: true # 击杀时完全恢复玩家的生命值和饥饿值
natural-regen: true # 事件期间原版自然生命值恢复
数据 (kits.yml)
存储主事件预设、队伍出生点列表、自由对战 (FFA) 出生点配置以及每位玩家的个人预设。此文件在首次运行时自动创建——通常无需手动编辑。
依赖要求
- Paper(或基于 Paper 的分叉版本)——该插件使用了 Paper/Adventure API(包括 Adventure 文本组件、
AsyncChatEvent 以及现代世界高度相关方法)。
- Java 17+(需匹配你的服务器所运行的 Minecraft 版本的 Java 要求)。
注意事项与限制
- 获胜者/队伍颜色从固定的小调色板(Minecraft 的传统聊天颜色)中提取,而非任意 RGB 值,因为计分板队伍的颜色仅支持该调色板。
natural-regen 开关仅影响当前处于事件中的玩家——它会在玩家个体层面取消自然(食物驱动)恢复,而不会修改世界的 gamerule,因此未参与的玩家及世界本身不受影响。其他治疗来源(药水、预设、击杀回血等)无论此开关状态如何均正常工作。
- 自由对战 (FFA) 出生点生成会自动验证地面安全性;手动放置的队伍/精确 FFA 出生点也会进行检查,但仅产生警告(系统信任管理员的手动放置,优先于自动回退机制)。
Custom Teams
Plugin made by imNikos.
A Paper/Bukkit plugin for running admin-controlled PvP events — either Free-For-All or 4-Team battles — complete with GUI-driven setup, custom kits, smart spawn placement, and per-player kit saving.
Features
- Two event modes
- Free-For-All (FFA): any number of players, each fighting solo with a white nametag. The winner's own name is announced instead of a team name.
- Teams: 4 fixed teams — Red, Blue, Green, Yellow — using light color variants for nametags, tab list, and chat prefixes.
- Flexible spawn systems
- Teams: set multiple spawn points per team using an in-world hotbar tool.
- FFA: choose between placing one spawn point per player, or a single center point that automatically spreads players around it in a radius that scales with player count.
- All auto-generated spawn locations are checked for safe, non-suffocating ground before use.
- Master event kit editor — build a shared kit (armor, offhand, potion effects, and 27 inventory slots) that every participant receives at match start.
- Personal kit saver — every player can save and load up to 3 of their own kits, independent of the event kit.
- Match safety windows
- 5 seconds of invincibility (and inability to deal damage) when a match starts, so no one gets ambushed while loading in.
- 10 seconds of invincibility for the winner(s) during the victory celebration.
- Configurable toggles — starting gamemode, health-on-kill, and natural regeneration, all switchable from the admin GUI.
- Automatic spectating — players who die are moved to spectator mode and can rejoin as a spectator or leave the event entirely.
- Persistent data — kits and spawn points are stored in
kits.yml and survive server restarts.
Commands
| Command |
Description |
Permission |
/ct |
Opens the admin control panel (Teams, Spawns, Kit Creator, toggles, Start/End Event). |
customteams.admin |
/ct leave |
Leave the currently running event and restore your pre-event inventory/location. |
none |
/ct kits |
Open your personal "My Kits" menu (save/load up to 3 personal kits). |
none |
Tab-completion suggests leave and kits after /ct.
Permissions
| Permission |
Description |
customteams.admin |
Access to the admin panel: team/roster management, spawn setup, kit creation, and starting/ending events. |
Any player (with or without the admin permission) can use /ct leave and /ct kits.
Admin GUI Walkthrough
Run /ct to open Custom Teams Settings:
-
Teams → Choose how the next event will be populated:
- Free-For-All (FFA) → opens a paginated player selector. Click players to toggle their selection, then Confirm & Set FFA Roster to lock it in.
- Manual Teams → pick a color, then click players to assign/unassign them to that team.
-
Spawns → Choose which spawn system to configure:
-
FFA Spawns → requires an FFA roster to already be set (so the plugin knows how many spawn points are needed). Then pick:
- Exact Spawn Points — you're handed one white wool per participant; place each one where you want a player to spawn.
- Radius Spawn Point — you're handed a single white wool; place it once as the center, and players will be spread evenly around it at a distance that grows with player count.
-
Team Spawns → enters an in-world editing mode with this hotbar layout:
| Slot |
Item |
| 1 |
Red spawn point (place to add a Red spawn) |
| 2 |
Blue spawn point |
| 3 |
Green spawn point |
| 4 |
Yellow spawn point |
| 5 |
Red spawn reset (right-click to clear only Red's spawns) |
| 6 |
Blue spawn reset |
| 7 |
Green spawn reset |
| 8 |
Yellow spawn reset |
| 9 |
Save and Exit |
In your main inventory you'll also find Cancel (discard all changes) and Reset All (clear every team's spawns). Nothing is written to disk until you hit Save and Exit.
-
Kit Creator → build the shared master event kit: drag items onto the armor/offhand slots and potion-effect slots, then click the emerald block to save.
-
Gamemode / Natural Regen / Health on Kill toggles → click to flip each setting; changes are saved to config.yml immediately.
-
Start Event / Force End Event → starts a 5-second countdown (visible as a title to all queued participants) or immediately ends a running event.
Personal Kits (/ct kits)
Every player has 3 personal kit slots, independent of the admin's master kit:
- Left-click a slot to load that saved kit into your current inventory.
- Right-click a slot to save your current inventory into it.
These are stored per-player and persist across sessions.
Configuration (config.yml)
settings:
gamemode-on-start: SURVIVAL # or ADVENTURE
health-on-kill: true # fully heal/feed a player on a kill
natural-regen: true # vanilla natural health regeneration during events
Data (kits.yml)
Stores the master event kit, team spawn lists, FFA spawn configuration, and each player's personal kits. This file is created automatically on first run — you shouldn't need to edit it by hand.
Requirements
- Paper (or a Paper-based fork) — the plugin uses Paper/Adventure APIs (Adventure text components,
AsyncChatEvent, modern world height methods).
- Java 17+ (matching your server's Minecraft version requirements).
Notes & Limitations
- Winner/team colors are drawn from a fixed, small palette (Minecraft's legacy chat colors) rather than arbitrary RGB, since scoreboard team colors are limited to that palette.
- The natural-regeneration toggle only affects players who are currently in the event — it cancels natural (food-driven) regeneration on a per-player basis rather than touching the world's gamerule, so non-participants and the world itself are unaffected. Other heal sources (potions, kits, health-on-kill) still work normally regardless of this toggle.
- FFA spawn generation validates ground safety automatically; manually placed team/exact-FFA spawn points are checked too, but only produce a warning (the admin's placement is trusted over the automated fallback).
评论 0
登录后参与评分
还没有评论,来抢沙发吧