mirror of
https://github.com/CarmJos/MoeTeleport.git
synced 2026-06-04 07:48:16 +08:00
[2.0.0] 版本更新
- [A] 添加消息点击执行功能(基于MineDown实现)。
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package cc.carm.plugin.moeteleport;
|
||||
|
||||
import cc.carm.plugin.moeteleport.command.BackCommand;
|
||||
import cc.carm.plugin.moeteleport.command.MoeTeleportCommand;
|
||||
import cc.carm.plugin.moeteleport.command.completer.HomeNameCompleter;
|
||||
import cc.carm.plugin.moeteleport.command.completer.PlayerNameCompleter;
|
||||
import cc.carm.plugin.moeteleport.command.completer.TpRequestCompleter;
|
||||
@@ -109,6 +110,8 @@ public class Main extends JavaPlugin {
|
||||
regListener(new UserListener());
|
||||
|
||||
log("注册指令...");
|
||||
registerCommand("MoeTeleport", new MoeTeleportCommand());
|
||||
|
||||
registerCommand("back", new BackCommand());
|
||||
|
||||
registerCommand("home", new GoHomeCommand(), new HomeNameCompleter());
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
package cc.carm.plugin.moeteleport.util;
|
||||
|
||||
import de.themoep.minedown.MineDown;
|
||||
import me.clip.placeholderapi.PlaceholderAPI;
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.command.CommandSender;
|
||||
@@ -17,7 +18,7 @@ public class MessageUtil {
|
||||
public static void send(@Nullable CommandSender sender, List<String> messages) {
|
||||
if (messages == null || messages.isEmpty() || sender == null) return;
|
||||
for (String s : messages) {
|
||||
sender.sendMessage(ColorParser.parse(s));
|
||||
sender.spigot().sendMessage(MineDown.parse(s));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -8,12 +8,12 @@ not-online:
|
||||
- "&f目标玩家并不在线,无法发送请求。"
|
||||
tpa:
|
||||
- "&d%(player) &f请求传送到您身边,您有 &5%(expire)秒 &f的时间回应。"
|
||||
- "&a&l[command=/tpAccept %(player)][同意][/command] &f输入 &5/tpaccept &f同意该请求。"
|
||||
- "&c&l[command=/tpDeny %(player)][拒绝][/command] &f输入 &5/tpdeny &f拒绝该请求。"
|
||||
- "[&a&l[同意]](show_text=点击同意请求 run_command=/tpAccept %(player)) &f输入 &5/tpAccept &f同意该请求。"
|
||||
- "[&c&l[拒绝]](show_text=点击拒绝请求 run_command=/tpDeny %(player)) &f输入 &5/tpDeny &f拒绝该请求。"
|
||||
tpahere:
|
||||
- "&d%(player) &f请求传送您到Ta身边,您有 &5%(expire)秒 &f的时间回应。"
|
||||
- "&a&l[command=/tpAccept %(player)][同意][/command] &f输入 &5/tpaccept &f同意该请求。"
|
||||
- "&c&l[command=/tpDeny %(player)][拒绝][/command] &f输入 &5/tpdeny &f拒绝该请求。"
|
||||
- "[&a&l[同意]](show_text=点击同意请求 run_command=/tpAccept %(player)) &f输入 &5/tpAccept &f同意该请求。"
|
||||
- "[&c&l[拒绝]](show_text=点击拒绝请求 run_command=/tpDeny %(player)) &f输入 &5/tpDeny &f拒绝该请求。"
|
||||
tpaccept:
|
||||
- "&f您同意了 &d%(player) &f的传送请求。"
|
||||
tpdeny:
|
||||
@@ -54,7 +54,7 @@ notAvailable:
|
||||
|
||||
home-list-header:
|
||||
- "&f您当前设定的所有家:"
|
||||
home-list-object: "&8# &f%(id) &d%(location) &7[command=/home %(id)]✈[/command]"
|
||||
home-list-object: "&8# &f%(id) &d%(location) [&7✈](show_text=点击返回家 %(id) run_command=/home %(id))"
|
||||
home-not-found:
|
||||
- "&f您还没有设置这个家,请先输入 &5/setHome <家名称> &f设置一个吧!"
|
||||
home-set:
|
||||
|
||||
Reference in New Issue
Block a user