LunaChat v3-k2 : BungeeCord implementation. (WIP)
このコミットが含まれているのは:
1 親
330fb0aaab
コミット
6202f00729
98ファイル変更
+1149
-715
検索条件に一致するファイルはありません
@@ -1,189 +0,0 @@
|
||||
/*
|
||||
* @author ucchy
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.bungee;
|
||||
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.concurrent.TimeUnit;
|
||||
import java.util.regex.Matcher;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc.Utility;
|
||||
import com.github.ucchyocean.lc.japanize.Japanizer;
|
||||
|
||||
import net.md_5.bungee.api.CommandSender;
|
||||
import net.md_5.bungee.api.chat.TextComponent;
|
||||
import net.md_5.bungee.api.config.ServerInfo;
|
||||
import net.md_5.bungee.api.connection.ProxiedPlayer;
|
||||
import net.md_5.bungee.api.event.ChatEvent;
|
||||
import net.md_5.bungee.api.plugin.Listener;
|
||||
import net.md_5.bungee.event.EventHandler;
|
||||
|
||||
/**
|
||||
* BungeeCordのイベントを監視するリスナークラス
|
||||
* @author ucchy
|
||||
*/
|
||||
public class BungeeEventListener implements Listener {
|
||||
|
||||
private static final String DATE_FORMAT_PATTERN = "yyyy/MM/dd";
|
||||
private static final String TIME_FORMAT_PATTERN = "HH:mm:ss";
|
||||
|
||||
private SimpleDateFormat dateFormat;
|
||||
private SimpleDateFormat timeFormat;
|
||||
private LunaChatBungee parent;
|
||||
private LunaChatConfig config;
|
||||
|
||||
/**
|
||||
* コンストラクタ
|
||||
* @param parent LunaChatBungeeのインスタンス
|
||||
*/
|
||||
protected BungeeEventListener(LunaChatBungee parent) {
|
||||
this.parent = parent;
|
||||
config = parent.getConfig();
|
||||
dateFormat = new SimpleDateFormat(DATE_FORMAT_PATTERN);
|
||||
timeFormat = new SimpleDateFormat(TIME_FORMAT_PATTERN);
|
||||
}
|
||||
|
||||
/**
|
||||
* プレイヤーがチャット発言した時に呼び出されるメソッド
|
||||
* @param event
|
||||
*/
|
||||
@EventHandler
|
||||
public void onChat(ChatEvent event) {
|
||||
|
||||
// 設定が無効なら、そのまま無視する
|
||||
if ( !config.isBroadcastChat() ) {
|
||||
return;
|
||||
}
|
||||
|
||||
// コマンド実行の場合は、そのまま無視する
|
||||
if ( event.isCommand() ) {
|
||||
return;
|
||||
}
|
||||
|
||||
// プレイヤーの発言ではない場合は、そのまま無視する
|
||||
if ( !(event.getSender() instanceof ProxiedPlayer) ) {
|
||||
return;
|
||||
}
|
||||
|
||||
// 発言者と発言サーバーと発言内容の取得
|
||||
final ProxiedPlayer sender = (ProxiedPlayer)event.getSender();
|
||||
String senderServer = sender.getServer().getInfo().getName();
|
||||
String message = event.getMessage();
|
||||
|
||||
// NGワードのマスク
|
||||
message = maskNGWord(message, config.getNgwordCompiled());
|
||||
|
||||
// Japanizeの付加
|
||||
if ( message.startsWith(config.getNoneJapanizeMarker()) ) {
|
||||
|
||||
message = message.substring(config.getNoneJapanizeMarker().length());
|
||||
|
||||
} else {
|
||||
|
||||
String japanize = Japanizer.japanize(message, config.getJapanizeType(),
|
||||
LunaChat.getAPI().getAllDictionary());
|
||||
if ( japanize.length() > 0 ) {
|
||||
|
||||
// NGワードのマスク
|
||||
japanize = maskNGWord(japanize, config.getNgwordCompiled());
|
||||
|
||||
// フォーマット化してメッセージを上書きする
|
||||
String japanizeFormat = config.getJapanizeDisplayLine() == 1 ?
|
||||
config.getJapanizeLine1Format() :
|
||||
"%msg\n" + config.getJapanizeLine2Format();
|
||||
String preMessage = new String(message);
|
||||
message = japanizeFormat.replace("%msg", preMessage).replace("%japanize", japanize);
|
||||
}
|
||||
}
|
||||
|
||||
// フォーマットの置き換え処理
|
||||
String result = config.getBroadcastChatFormat();
|
||||
result = result.replace("%senderserver", senderServer);
|
||||
result = result.replace("%sender", sender.getName());
|
||||
if ( result.contains("%date") ) {
|
||||
result = result.replace("%date", dateFormat.format(new Date()));
|
||||
}
|
||||
if ( result.contains("%time") ) {
|
||||
result = result.replace("%time", timeFormat.format(new Date()));
|
||||
}
|
||||
result = result.replace("%msg", message);
|
||||
result = Utility.replaceColorCode(result);
|
||||
|
||||
// 発言したプレイヤーがいるサーバー"以外"のサーバーに、
|
||||
// 発言内容を送信する。
|
||||
for ( String server : parent.getProxy().getServers().keySet() ) {
|
||||
|
||||
if ( server.equals(senderServer) ) {
|
||||
continue;
|
||||
}
|
||||
|
||||
ServerInfo info = parent.getProxy().getServerInfo(server);
|
||||
for ( ProxiedPlayer player : info.getPlayers() ) {
|
||||
sendMessage(player, result);
|
||||
}
|
||||
}
|
||||
|
||||
// ローカルも置き換える処理なら、置換えを行う
|
||||
if ( config.isBroadcastChatLocalJapanize() ) {
|
||||
|
||||
// NOTE: 改行がサポートされないので、改行を含む場合は、
|
||||
// \nで分割して前半をセットし、後半は150ミリ秒後に送信する。
|
||||
if ( !message.contains("\n") ) {
|
||||
event.setMessage(Utility.stripColorCode(message));
|
||||
} else {
|
||||
int index = message.indexOf("\n");
|
||||
String pre = message.substring(0, index);
|
||||
final String post = Utility.replaceColorCode(
|
||||
message.substring(index + "\n".length()));
|
||||
event.setMessage(Utility.stripColorCode(pre));
|
||||
parent.getProxy().getScheduler().schedule(parent, new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
for ( ProxiedPlayer p : sender.getServer().getInfo().getPlayers() ) {
|
||||
sendMessage(p, post);
|
||||
}
|
||||
}
|
||||
}, 150, TimeUnit.MILLISECONDS);
|
||||
}
|
||||
}
|
||||
|
||||
// コンソールに表示設定なら、コンソールに表示する
|
||||
if ( config.isDisplayChatOnConsole() ) {
|
||||
parent.getLogger().info(result);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* NGワードをマスクする
|
||||
* @param message メッセージ
|
||||
* @param ngwords NGワード
|
||||
* @return マスクされたメッセージ
|
||||
*/
|
||||
private String maskNGWord(String message, List<Pattern> ngwords) {
|
||||
for ( Pattern pattern : ngwords ) {
|
||||
Matcher matcher = pattern.matcher(message);
|
||||
if ( matcher.find() ) {
|
||||
message = matcher.replaceAll(
|
||||
Utility.getAstariskString(matcher.group(0).length()));
|
||||
}
|
||||
}
|
||||
return message;
|
||||
}
|
||||
|
||||
/**
|
||||
* 指定した対象にメッセージを送信する
|
||||
* @param reciever 送信先
|
||||
* @param message メッセージ
|
||||
*/
|
||||
private void sendMessage(CommandSender reciever, String message) {
|
||||
if ( message == null ) return;
|
||||
reciever.sendMessage(TextComponent.fromLegacyText(message));
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,71 @@
|
||||
/*
|
||||
* @author ucchy
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc3;
|
||||
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
/**
|
||||
* チャットカラー
|
||||
* @author ucchy
|
||||
*/
|
||||
public enum ChatColor {
|
||||
|
||||
BLACK('0', 0x00),
|
||||
DARK_BLUE('1', 0x1),
|
||||
DARK_GREEN('2', 0x2),
|
||||
DARK_AQUA('3', 0x3),
|
||||
DARK_RED('4', 0x4),
|
||||
DARK_PURPLE('5', 0x5),
|
||||
GOLD('6', 0x6),
|
||||
GRAY('7', 0x7),
|
||||
DARK_GRAY('8', 0x8),
|
||||
BLUE('9', 0x9),
|
||||
GREEN('a', 0xA),
|
||||
AQUA('b', 0xB),
|
||||
RED('c', 0xC),
|
||||
LIGHT_PURPLE('d', 0xD),
|
||||
YELLOW('e', 0xE),
|
||||
WHITE('f', 0xF),
|
||||
MAGIC('k', 0x10, true),
|
||||
BOLD('l', 0x11, true),
|
||||
STRIKETHROUGH('m', 0x12, true),
|
||||
UNDERLINE('n', 0x13, true),
|
||||
ITALIC('o', 0x14, true),
|
||||
RESET('r', 0x15);
|
||||
|
||||
public static final char COLOR_CHAR = '\u00A7';
|
||||
|
||||
@SuppressWarnings("unused")
|
||||
private final int intCode;
|
||||
private final char code;
|
||||
private final boolean isFormat;
|
||||
private final String toString;
|
||||
|
||||
private ChatColor(char code, int intCode) {
|
||||
this(code, intCode, false);
|
||||
}
|
||||
|
||||
private ChatColor(char code, int intCode, boolean isFormat) {
|
||||
this.code = code;
|
||||
this.intCode = intCode;
|
||||
this.isFormat = isFormat;
|
||||
this.toString = new String(new char[] {COLOR_CHAR, code});
|
||||
}
|
||||
|
||||
public char getChar() {
|
||||
return code;
|
||||
}
|
||||
|
||||
@NotNull
|
||||
@Override
|
||||
public String toString() {
|
||||
return toString;
|
||||
}
|
||||
|
||||
public boolean isFormat() {
|
||||
return isFormat;
|
||||
}
|
||||
}
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc;
|
||||
package com.github.ucchyocean.lc3;
|
||||
|
||||
/**
|
||||
* Event優先度列挙子(Bukkit用)
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc;
|
||||
package com.github.ucchyocean.lc3;
|
||||
|
||||
import java.io.File;
|
||||
|
||||
+4
-4
@@ -3,16 +3,16 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc;
|
||||
package com.github.ucchyocean.lc3;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* LunaChat APIクラス
|
||||
+2
-2
@@ -3,14 +3,14 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc;
|
||||
package com.github.ucchyocean.lc3;
|
||||
|
||||
import java.io.File;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
import com.github.ucchyocean.lc.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc3.japanize.JapanizeType;
|
||||
|
||||
/**
|
||||
* LunaChatのコンフィグクラス
|
||||
+2
-4
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc;
|
||||
package com.github.ucchyocean.lc3;
|
||||
|
||||
import java.io.BufferedReader;
|
||||
import java.io.File;
|
||||
@@ -18,8 +18,6 @@ import java.util.Calendar;
|
||||
import java.util.Collections;
|
||||
import java.util.Date;
|
||||
|
||||
import org.bukkit.ChatColor;
|
||||
|
||||
/**
|
||||
* LunaChatロガー
|
||||
* @author ucchy
|
||||
@@ -64,7 +62,7 @@ public class LunaChatLogger {
|
||||
@Override
|
||||
public void run() {
|
||||
|
||||
String msg = ChatColor.stripColor(message);
|
||||
String msg = Utility.stripColorCode(message);
|
||||
if ( msg == null ) msg = "";
|
||||
msg = msg.replace(",", ",");
|
||||
FileWriter writer = null;
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc;
|
||||
package com.github.ucchyocean.lc3;
|
||||
|
||||
/**
|
||||
* LunaChatの動作モード
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc;
|
||||
package com.github.ucchyocean.lc3;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc;
|
||||
package com.github.ucchyocean.lc3;
|
||||
|
||||
|
||||
/**
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc;
|
||||
package com.github.ucchyocean.lc3;
|
||||
|
||||
import java.io.File;
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc;
|
||||
package com.github.ucchyocean.lc3;
|
||||
|
||||
import java.io.BufferedReader;
|
||||
import java.io.BufferedWriter;
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc;
|
||||
package com.github.ucchyocean.lc3;
|
||||
|
||||
import java.util.Collection;
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc;
|
||||
package com.github.ucchyocean.lc3;
|
||||
|
||||
import java.io.BufferedWriter;
|
||||
import java.io.File;
|
||||
+5
-5
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.bridge;
|
||||
package com.github.ucchyocean.lc3.bridge;
|
||||
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.event.EventHandler;
|
||||
@@ -12,10 +12,10 @@ import org.bukkit.plugin.Plugin;
|
||||
import org.dynmap.DynmapAPI;
|
||||
import org.dynmap.DynmapWebChatEvent;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc3.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
|
||||
/**
|
||||
* dynmap連携クラス
|
||||
+9
-9
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.bridge;
|
||||
package com.github.ucchyocean.lc3.bridge;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.regex.Matcher;
|
||||
@@ -13,14 +13,14 @@ import org.bukkit.entity.Player;
|
||||
import org.bukkit.event.EventHandler;
|
||||
import org.bukkit.event.Listener;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc.Utility;
|
||||
import com.github.ucchyocean.lc.bukkit.LunaChatBukkit;
|
||||
import com.github.ucchyocean.lc.channel.DelayedJapanizeRecipientChatTask;
|
||||
import com.github.ucchyocean.lc.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc3.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc3.Utility;
|
||||
import com.github.ucchyocean.lc3.bukkit.LunaChatBukkit;
|
||||
import com.github.ucchyocean.lc3.channel.DelayedJapanizeRecipientChatTask;
|
||||
import com.github.ucchyocean.lc3.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
import com.gmail.nossr50.api.PartyAPI;
|
||||
import com.gmail.nossr50.events.chat.McMMOPartyChatEvent;
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.bridge;
|
||||
package com.github.ucchyocean.lc3.bridge;
|
||||
|
||||
import org.bukkit.World;
|
||||
import org.bukkit.plugin.Plugin;
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.bridge;
|
||||
package com.github.ucchyocean.lc3.bridge;
|
||||
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.entity.Player;
|
||||
+13
-13
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.bukkit;
|
||||
package com.github.ucchyocean.lc3.bukkit;
|
||||
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.ArrayList;
|
||||
@@ -23,18 +23,18 @@ import org.bukkit.event.player.AsyncPlayerChatEvent;
|
||||
import org.bukkit.event.player.PlayerJoinEvent;
|
||||
import org.bukkit.event.player.PlayerQuitEvent;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc.Messages;
|
||||
import com.github.ucchyocean.lc.Utility;
|
||||
import com.github.ucchyocean.lc.bridge.VaultChatBridge;
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.channel.DelayedJapanizeNormalChatTask;
|
||||
import com.github.ucchyocean.lc.event.LunaChatPreChatEvent;
|
||||
import com.github.ucchyocean.lc.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc.member.ChannelMemberBukkit;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc3.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc3.Messages;
|
||||
import com.github.ucchyocean.lc3.Utility;
|
||||
import com.github.ucchyocean.lc3.bridge.VaultChatBridge;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.channel.DelayedJapanizeNormalChatTask;
|
||||
import com.github.ucchyocean.lc3.event.LunaChatPreChatEvent;
|
||||
import com.github.ucchyocean.lc3.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMemberBukkit;
|
||||
|
||||
/**
|
||||
* Bukkit関連のイベントを監視するリスナ
|
||||
+3
-3
@@ -3,12 +3,12 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.bukkit;
|
||||
package com.github.ucchyocean.lc3.bukkit;
|
||||
|
||||
import org.bukkit.scheduler.BukkitRunnable;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
|
||||
/**
|
||||
* 各チャンネルの期限付きBANや期限付きMuteを、1分間隔で確認しに行くタスク
|
||||
+16
-16
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.bukkit;
|
||||
package com.github.ucchyocean.lc3.bukkit;
|
||||
|
||||
import java.io.File;
|
||||
import java.util.List;
|
||||
@@ -14,21 +14,21 @@ import org.bukkit.command.CommandSender;
|
||||
import org.bukkit.plugin.Plugin;
|
||||
import org.bukkit.plugin.java.JavaPlugin;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc.LunaChatLogger;
|
||||
import com.github.ucchyocean.lc.LunaChatMode;
|
||||
import com.github.ucchyocean.lc.PluginInterface;
|
||||
import com.github.ucchyocean.lc.bridge.DynmapBridge;
|
||||
import com.github.ucchyocean.lc.bridge.McMMOBridge;
|
||||
import com.github.ucchyocean.lc.bridge.MultiverseCoreBridge;
|
||||
import com.github.ucchyocean.lc.bridge.VaultChatBridge;
|
||||
import com.github.ucchyocean.lc.channel.ChannelManager;
|
||||
import com.github.ucchyocean.lc.command.LunaChatCommandBukkit;
|
||||
import com.github.ucchyocean.lc.command.LunaChatJapanizeCommand;
|
||||
import com.github.ucchyocean.lc.command.LunaChatMessageCommand;
|
||||
import com.github.ucchyocean.lc.command.LunaChatReplyCommand;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc3.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc3.LunaChatLogger;
|
||||
import com.github.ucchyocean.lc3.LunaChatMode;
|
||||
import com.github.ucchyocean.lc3.PluginInterface;
|
||||
import com.github.ucchyocean.lc3.bridge.DynmapBridge;
|
||||
import com.github.ucchyocean.lc3.bridge.McMMOBridge;
|
||||
import com.github.ucchyocean.lc3.bridge.MultiverseCoreBridge;
|
||||
import com.github.ucchyocean.lc3.bridge.VaultChatBridge;
|
||||
import com.github.ucchyocean.lc3.channel.ChannelManager;
|
||||
import com.github.ucchyocean.lc3.command.LunaChatCommandBukkit;
|
||||
import com.github.ucchyocean.lc3.command.LunaChatJapanizeCommand;
|
||||
import com.github.ucchyocean.lc3.command.LunaChatMessageCommand;
|
||||
import com.github.ucchyocean.lc3.command.LunaChatReplyCommand;
|
||||
|
||||
/**
|
||||
* LunaChatのBukkit実装
|
||||
@@ -0,0 +1,561 @@
|
||||
/*
|
||||
* @author ucchy
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc3.bungee;
|
||||
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.concurrent.TimeUnit;
|
||||
import java.util.regex.Matcher;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
import org.bukkit.ChatColor;
|
||||
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc3.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc3.Messages;
|
||||
import com.github.ucchyocean.lc3.Utility;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.japanize.Japanizer;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
import net.md_5.bungee.api.CommandSender;
|
||||
import net.md_5.bungee.api.chat.TextComponent;
|
||||
import net.md_5.bungee.api.config.ServerInfo;
|
||||
import net.md_5.bungee.api.connection.ProxiedPlayer;
|
||||
import net.md_5.bungee.api.event.ChatEvent;
|
||||
import net.md_5.bungee.api.event.PlayerDisconnectEvent;
|
||||
import net.md_5.bungee.api.event.PostLoginEvent;
|
||||
import net.md_5.bungee.api.plugin.Listener;
|
||||
import net.md_5.bungee.event.EventHandler;
|
||||
import net.md_5.bungee.event.EventPriority;
|
||||
|
||||
/**
|
||||
* BungeeCordのイベントを監視するリスナークラス
|
||||
* @author ucchy
|
||||
*/
|
||||
public class BungeeEventListener implements Listener {
|
||||
|
||||
private static final String MOTD_FIRSTLINE = Messages.get("motdFirstLine");
|
||||
private static final String LIST_ENDLINE = Messages.get("listEndLine");
|
||||
private static final String LIST_FORMAT = Messages.get("listFormat");
|
||||
private static final String PREERR = Messages.get("errorPrefix");
|
||||
|
||||
private static final String DATE_FORMAT_PATTERN = "yyyy/MM/dd";
|
||||
private static final String TIME_FORMAT_PATTERN = "HH:mm:ss";
|
||||
|
||||
private SimpleDateFormat dateFormat;
|
||||
private SimpleDateFormat timeFormat;
|
||||
private LunaChatBungee parent;
|
||||
private LunaChatConfig config;
|
||||
private LunaChatAPI api;
|
||||
|
||||
/**
|
||||
* コンストラクタ
|
||||
* @param parent LunaChatBungeeのインスタンス
|
||||
*/
|
||||
protected BungeeEventListener(LunaChatBungee parent) {
|
||||
this.parent = parent;
|
||||
config = parent.getConfig();
|
||||
api = parent.getLunaChatAPI();
|
||||
dateFormat = new SimpleDateFormat(DATE_FORMAT_PATTERN);
|
||||
timeFormat = new SimpleDateFormat(TIME_FORMAT_PATTERN);
|
||||
}
|
||||
|
||||
/**
|
||||
* プレイヤーがチャット発言したときに呼び出されるメソッド
|
||||
* @param event
|
||||
*/
|
||||
@EventHandler(priority=EventPriority.LOWEST)
|
||||
public void onAsyncPlayerChatLowest(ChatEvent event) {
|
||||
if ( matchesEventPriority(EventPriority.LOWEST) ) {
|
||||
processChatEvent(event);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* プレイヤーがチャット発言したときに呼び出されるメソッド
|
||||
* @param event
|
||||
*/
|
||||
@EventHandler(priority=EventPriority.LOW)
|
||||
public void onAsyncPlayerChatLow(ChatEvent event) {
|
||||
if ( matchesEventPriority(EventPriority.LOW) ) {
|
||||
processChatEvent(event);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* プレイヤーがチャット発言したときに呼び出されるメソッド
|
||||
* @param event
|
||||
*/
|
||||
@EventHandler(priority=EventPriority.NORMAL)
|
||||
public void onAsyncPlayerChatNormal(ChatEvent event) {
|
||||
if ( matchesEventPriority(EventPriority.NORMAL) ) {
|
||||
processChatEvent(event);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* プレイヤーがチャット発言したときに呼び出されるメソッド
|
||||
* @param event
|
||||
*/
|
||||
@EventHandler(priority=EventPriority.HIGH)
|
||||
public void onAsyncPlayerChatHigh(ChatEvent event) {
|
||||
if ( matchesEventPriority(EventPriority.HIGH) ) {
|
||||
processChatEvent(event);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* プレイヤーがチャット発言したときに呼び出されるメソッド
|
||||
* @param event
|
||||
*/
|
||||
@EventHandler(priority=EventPriority.HIGHEST)
|
||||
public void onAsyncPlayerChatHighest(ChatEvent event) {
|
||||
if ( matchesEventPriority(EventPriority.HIGHEST) ) {
|
||||
processChatEvent(event);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* プレイヤーが接続したときに呼び出されるメソッド
|
||||
* @param event プレイヤーログインイベント
|
||||
*/
|
||||
@EventHandler
|
||||
public void onJoin(PostLoginEvent event) {
|
||||
|
||||
LunaChatConfig config = LunaChat.getConfig();
|
||||
ProxiedPlayer player = event.getPlayer();
|
||||
|
||||
// 強制参加チャンネル設定を確認し、参加させる
|
||||
forceJoinToForceJoinChannels(player);
|
||||
|
||||
// グローバルチャンネル設定がある場合
|
||||
if ( !config.getGlobalChannel().equals("") ) {
|
||||
tryJoinToGlobalChannel(player);
|
||||
}
|
||||
|
||||
// チャンネルチャット情報を表示する
|
||||
if ( config.isShowListOnJoin() ) {
|
||||
ArrayList<String> list = getListForMotd(player);
|
||||
for ( String msg : list ) {
|
||||
player.sendMessage(TextComponent.fromLegacyText(msg));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* プレイヤーのサーバー退出ごとに呼び出されるメソッド
|
||||
* @param event プレイヤー退出イベント
|
||||
*/
|
||||
@EventHandler
|
||||
public void onQuit(PlayerDisconnectEvent event) {
|
||||
|
||||
ProxiedPlayer player = event.getPlayer();
|
||||
String pname = player.getName();
|
||||
|
||||
// お互いがオフラインになるPMチャンネルがある場合は
|
||||
// チャンネルをクリアする
|
||||
ArrayList<Channel> deleteList = new ArrayList<Channel>();
|
||||
|
||||
for ( Channel channel : LunaChat.getAPI().getChannels() ) {
|
||||
String cname = channel.getName();
|
||||
if ( channel.isPersonalChat() && cname.contains(pname) ) {
|
||||
boolean isAllOffline = true;
|
||||
for ( ChannelMember cp : channel.getMembers() ) {
|
||||
// TODO
|
||||
if ( cp.isOnline() ) {
|
||||
isAllOffline = false;
|
||||
}
|
||||
}
|
||||
if ( isAllOffline ) {
|
||||
deleteList.add(channel);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
for ( Channel channel : deleteList ) {
|
||||
LunaChat.getAPI().removeChannel(channel.getName());
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* プレイヤーのチャットごとに呼び出されるメソッド
|
||||
* @param event チャットイベント
|
||||
*/
|
||||
private void processChatEvent(ChatEvent event) {
|
||||
|
||||
// コマンド実行の場合は、そのまま無視する
|
||||
if ( event.isCommand() ) {
|
||||
return;
|
||||
}
|
||||
|
||||
// プレイヤーの発言ではない場合は、そのまま無視する
|
||||
if ( !(event.getSender() instanceof ProxiedPlayer) ) {
|
||||
return;
|
||||
}
|
||||
|
||||
// 頭にglobalMarkerが付いている場合は、グローバル発言にする
|
||||
if ( config.getGlobalMarker() != null &&
|
||||
!config.getGlobalMarker().equals("") &&
|
||||
event.getMessage().startsWith(config.getGlobalMarker()) &&
|
||||
event.getMessage().length() > config.getGlobalMarker().length() ) {
|
||||
|
||||
int offset = config.getGlobalMarker().length();
|
||||
event.setMessage( event.getMessage().substring(offset) );
|
||||
chatGlobal(event);
|
||||
return;
|
||||
}
|
||||
|
||||
// クイックチャンネルチャット機能が有効で、専用の記号が含まれるなら、
|
||||
// クイックチャンネルチャットとして処理する。
|
||||
if ( config.isEnableQuickChannelChat() ) {
|
||||
String separator = config.getQuickChannelChatSeparator();
|
||||
if ( event.getMessage().contains(separator) ) {
|
||||
String[] temp = event.getMessage().split(separator, 2);
|
||||
String name = temp[0];
|
||||
String value = "";
|
||||
if ( temp.length > 0 ) {
|
||||
value = temp[1];
|
||||
}
|
||||
|
||||
Channel channel = api.getChannel(name);
|
||||
if ( channel != null && !channel.isPersonalChat()
|
||||
&& event.getSender() instanceof ProxiedPlayer ) {
|
||||
ChannelMember player =
|
||||
ChannelMember.getChannelMember(event.getSender());
|
||||
if ( !channel.getMembers().contains(player) ) {
|
||||
// 指定されたチャンネルに参加していないなら、エラーを表示して何も発言せずに終了する。
|
||||
sendResourceMessage((ProxiedPlayer)event.getSender(), PREERR, "errmsgNomember");
|
||||
event.setCancelled(true);
|
||||
return;
|
||||
}
|
||||
|
||||
// 指定されたチャンネルに発言して終了する。
|
||||
chatToChannelWithEvent(player, channel, value);
|
||||
event.setCancelled(true);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
ChannelMember player =
|
||||
ChannelMember.getChannelMember(event.getSender());
|
||||
Channel channel = api.getDefaultChannel(player.getName());
|
||||
|
||||
// デフォルトの発言先が無い場合
|
||||
if ( channel == null ) {
|
||||
if ( config.isNoJoinAsGlobal() ) {
|
||||
// グローバル発言にする
|
||||
chatGlobal(event);
|
||||
return;
|
||||
|
||||
} else {
|
||||
// 発言をキャンセルして終了する
|
||||
event.setCancelled(true);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
chatToChannelWithEvent(player, channel, event.getMessage());
|
||||
|
||||
// もとのイベントをキャンセル
|
||||
event.setCancelled(true);
|
||||
}
|
||||
|
||||
private void chatGlobal(ChatEvent event) {
|
||||
|
||||
// 発言者と発言サーバーと発言内容の取得
|
||||
final ProxiedPlayer sender = (ProxiedPlayer)event.getSender();
|
||||
String senderServer = sender.getServer().getInfo().getName();
|
||||
String message = event.getMessage();
|
||||
LunaChatConfig config = LunaChat.getConfig();
|
||||
|
||||
// NGワードのマスク
|
||||
message = maskNGWord(message, config.getNgwordCompiled());
|
||||
|
||||
// Japanizeの付加
|
||||
if ( message.startsWith(config.getNoneJapanizeMarker()) ) {
|
||||
|
||||
message = message.substring(config.getNoneJapanizeMarker().length());
|
||||
|
||||
} else {
|
||||
|
||||
String japanize = Japanizer.japanize(message, config.getJapanizeType(),
|
||||
LunaChat.getAPI().getAllDictionary());
|
||||
if ( japanize.length() > 0 ) {
|
||||
|
||||
// NGワードのマスク
|
||||
japanize = maskNGWord(japanize, config.getNgwordCompiled());
|
||||
|
||||
// フォーマット化してメッセージを上書きする
|
||||
String japanizeFormat = config.getJapanizeDisplayLine() == 1 ?
|
||||
config.getJapanizeLine1Format() :
|
||||
"%msg\n" + config.getJapanizeLine2Format();
|
||||
String preMessage = new String(message);
|
||||
message = japanizeFormat.replace("%msg", preMessage).replace("%japanize", japanize);
|
||||
}
|
||||
}
|
||||
|
||||
// フォーマットの置き換え処理
|
||||
String result = config.getBroadcastChatFormat();
|
||||
result = result.replace("%senderserver", senderServer);
|
||||
result = result.replace("%player", sender.getName());
|
||||
result = result.replace("%username", sender.getDisplayName());
|
||||
if ( result.contains("%date") ) {
|
||||
result = result.replace("%date", dateFormat.format(new Date()));
|
||||
}
|
||||
if ( result.contains("%time") ) {
|
||||
result = result.replace("%time", timeFormat.format(new Date()));
|
||||
}
|
||||
result = result.replace("%msg", message);
|
||||
result = Utility.replaceColorCode(result);
|
||||
|
||||
// 発言したプレイヤーがいるサーバー"以外"のサーバーに、
|
||||
// 発言内容を送信する。
|
||||
for ( String server : parent.getProxy().getServers().keySet() ) {
|
||||
|
||||
if ( server.equals(senderServer) ) {
|
||||
continue;
|
||||
}
|
||||
|
||||
ServerInfo info = parent.getProxy().getServerInfo(server);
|
||||
for ( ProxiedPlayer player : info.getPlayers() ) {
|
||||
sendMessage(player, result);
|
||||
}
|
||||
}
|
||||
|
||||
// ローカルも置き換える処理なら、置換えを行う
|
||||
if ( config.isBroadcastChatLocalJapanize() ) {
|
||||
|
||||
// NOTE: 改行がサポートされないので、改行を含む場合は、
|
||||
// \nで分割して前半をセットし、後半は150ミリ秒後に送信する。
|
||||
if ( !message.contains("\n") ) {
|
||||
event.setMessage(Utility.stripColorCode(message));
|
||||
} else {
|
||||
int index = message.indexOf("\n");
|
||||
String pre = message.substring(0, index);
|
||||
final String post = Utility.replaceColorCode(
|
||||
message.substring(index + "\n".length()));
|
||||
event.setMessage(Utility.stripColorCode(pre));
|
||||
parent.getProxy().getScheduler().schedule(parent, new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
for ( ProxiedPlayer p : sender.getServer().getInfo().getPlayers() ) {
|
||||
sendMessage(p, post);
|
||||
}
|
||||
}
|
||||
}, 150, TimeUnit.MILLISECONDS);
|
||||
}
|
||||
}
|
||||
|
||||
// コンソールに表示設定なら、コンソールに表示する
|
||||
if ( config.isDisplayChatOnConsole() ) {
|
||||
parent.getLogger().info(result);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* チャンネルに発言処理を行う
|
||||
* @param player プレイヤー
|
||||
* @param channel チャンネル
|
||||
* @param message 発言内容
|
||||
* @return イベントでキャンセルされたかどうか
|
||||
*/
|
||||
private boolean chatToChannelWithEvent(ChannelMember player, Channel channel, String message) {
|
||||
|
||||
// LunaChatPreChatEvent イベントコール
|
||||
// LunaChatPreChatEvent preChatEvent = new LunaChatPreChatEvent(
|
||||
// channel.getName(), player, message);
|
||||
// Bukkit.getPluginManager().callEvent(preChatEvent);
|
||||
// if ( preChatEvent.isCancelled() ) {
|
||||
// return true;
|
||||
// }
|
||||
// Channel alt = preChatEvent.getChannel();
|
||||
// if ( alt != null ) {
|
||||
// channel = alt;
|
||||
// }
|
||||
// message = preChatEvent.getMessage();
|
||||
|
||||
// チャンネルチャット発言
|
||||
channel.chat(player, message);
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* NGワードをマスクする
|
||||
* @param message メッセージ
|
||||
* @param ngwords NGワード
|
||||
* @return マスクされたメッセージ
|
||||
*/
|
||||
private String maskNGWord(String message, List<Pattern> ngwords) {
|
||||
for ( Pattern pattern : ngwords ) {
|
||||
Matcher matcher = pattern.matcher(message);
|
||||
if ( matcher.find() ) {
|
||||
message = matcher.replaceAll(
|
||||
Utility.getAstariskString(matcher.group(0).length()));
|
||||
}
|
||||
}
|
||||
return message;
|
||||
}
|
||||
|
||||
/**
|
||||
* 強制参加チャンネルへ参加させる
|
||||
* @param player プレイヤー
|
||||
*/
|
||||
private void forceJoinToForceJoinChannels(ProxiedPlayer player) {
|
||||
|
||||
LunaChatConfig config = LunaChat.getConfig();
|
||||
LunaChatAPI api = LunaChat.getAPI();
|
||||
|
||||
List<String> forceJoinChannels = config.getForceJoinChannels();
|
||||
|
||||
for ( String cname : forceJoinChannels ) {
|
||||
|
||||
// チャンネルが存在しない場合は作成する
|
||||
Channel channel = api.getChannel(cname);
|
||||
if ( channel == null ) {
|
||||
channel = api.createChannel(cname);
|
||||
}
|
||||
|
||||
// チャンネルのメンバーでないなら、参加する
|
||||
ChannelMember cp = ChannelMember.getChannelMember(player);
|
||||
if ( !channel.getMembers().contains(cp) ) {
|
||||
channel.addMember(cp);
|
||||
}
|
||||
|
||||
// デフォルト発言先が無いなら、グローバルチャンネルに設定する
|
||||
Channel dchannel = api.getDefaultChannel(player.getName());
|
||||
if ( dchannel == null ) {
|
||||
api.setDefaultChannel(player.getName(), cname);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 既定のチャンネルへの参加を試みる。
|
||||
* @param player プレイヤー
|
||||
* @return 参加できたかどうか
|
||||
*/
|
||||
private boolean tryJoinToGlobalChannel(ProxiedPlayer player) {
|
||||
|
||||
LunaChatConfig config = LunaChat.getConfig();
|
||||
LunaChatAPI api = LunaChat.getAPI();
|
||||
|
||||
String gcName = config.getGlobalChannel();
|
||||
|
||||
// チャンネルが存在しない場合は作成する
|
||||
Channel global = api.getChannel(gcName);
|
||||
if ( global == null ) {
|
||||
global = api.createChannel(gcName);
|
||||
}
|
||||
|
||||
// デフォルト発言先が無いなら、グローバルチャンネルに設定する
|
||||
Channel dchannel = api.getDefaultChannel(player.getName());
|
||||
if ( dchannel == null ) {
|
||||
api.setDefaultChannel(player.getName(), gcName);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* プレイヤーのサーバー参加時用の参加チャンネルリストを返す
|
||||
* @param player プレイヤー
|
||||
* @return リスト
|
||||
*/
|
||||
private ArrayList<String> getListForMotd(ProxiedPlayer player) {
|
||||
|
||||
ChannelMember cp = ChannelMember.getChannelMember(player);
|
||||
LunaChatAPI api = LunaChat.getAPI();
|
||||
Channel dc = api.getDefaultChannel(cp.getName());
|
||||
String dchannel = "";
|
||||
if ( dc != null ) {
|
||||
dchannel = dc.getName().toLowerCase();
|
||||
}
|
||||
|
||||
ArrayList<String> items = new ArrayList<String>();
|
||||
items.add(MOTD_FIRSTLINE);
|
||||
for ( Channel channel : api.getChannels() ) {
|
||||
|
||||
// BANされているチャンネルは表示しない
|
||||
if ( channel.getBanned().contains(cp) ) {
|
||||
continue;
|
||||
}
|
||||
|
||||
// 個人チャットはリストに表示しない
|
||||
if ( channel.isPersonalChat() ) {
|
||||
continue;
|
||||
}
|
||||
|
||||
// 参加していないチャンネルは、グローバルチャンネルを除き表示しない
|
||||
if ( !channel.getMembers().contains(cp) &&
|
||||
!channel.isGlobalChannel() ) {
|
||||
continue;
|
||||
}
|
||||
|
||||
String disp = ChatColor.WHITE + channel.getName();
|
||||
if ( channel.getName().equals(dchannel) ) {
|
||||
disp = ChatColor.RED + channel.getName();
|
||||
}
|
||||
String desc = channel.getDescription();
|
||||
int onlineNum = channel.getOnlineNum();
|
||||
int memberNum = channel.getTotalNum();
|
||||
String item = String.format(
|
||||
LIST_FORMAT, disp, onlineNum, memberNum, desc);
|
||||
items.add(item);
|
||||
}
|
||||
items.add(LIST_ENDLINE);
|
||||
|
||||
return items;
|
||||
}
|
||||
|
||||
/**
|
||||
* 指定した対象にメッセージを送信する
|
||||
* @param reciever 送信先
|
||||
* @param message メッセージ
|
||||
*/
|
||||
private void sendMessage(CommandSender reciever, String message) {
|
||||
if ( message == null ) return;
|
||||
reciever.sendMessage(TextComponent.fromLegacyText(message));
|
||||
}
|
||||
|
||||
/**
|
||||
* メッセージリソースのメッセージを、カラーコード置き換えしつつ、senderに送信する
|
||||
* @param sender メッセージの送り先
|
||||
* @param pre プレフィックス
|
||||
* @param key リソースキー
|
||||
* @param args リソース内の置き換え対象キーワード
|
||||
*/
|
||||
private void sendResourceMessage(
|
||||
CommandSender sender, String pre, String key, Object... args) {
|
||||
|
||||
String org = Messages.get(key);
|
||||
if ( org == null || org.equals("") ) {
|
||||
return;
|
||||
}
|
||||
String msg = String.format(pre + org, args);
|
||||
sender.sendMessage(TextComponent.fromLegacyText(msg));
|
||||
}
|
||||
|
||||
/**
|
||||
* 指定されたEventPriorityが、LunaChatConfigで指定されているEventPriorityと一致するかどうかを調べる
|
||||
* @param priority
|
||||
* @return 一致するかどうか
|
||||
*/
|
||||
private boolean matchesEventPriority(int priority) {
|
||||
String c = LunaChat.getConfig().getPlayerChatEventListenerPriority().name();
|
||||
if ( priority == EventPriority.LOWEST ) return "LOWEST".equals(c);
|
||||
if ( priority == EventPriority.LOW ) return "LOW".equals(c);
|
||||
if ( priority == EventPriority.NORMAL ) return "NORMAL".equals(c);
|
||||
if ( priority == EventPriority.HIGH ) return "HIGH".equals(c);
|
||||
if ( priority == EventPriority.HIGHEST ) return "HIGHEST".equals(c);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
+2
-2
@@ -3,11 +3,11 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.bungee;
|
||||
package com.github.ucchyocean.lc3.bungee;
|
||||
|
||||
import java.util.HashMap;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
|
||||
import net.md_5.bungee.api.ChatColor;
|
||||
import net.md_5.bungee.api.CommandSender;
|
||||
+11
-11
@@ -3,18 +3,18 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.bungee;
|
||||
package com.github.ucchyocean.lc3.bungee;
|
||||
|
||||
import java.io.File;
|
||||
import java.util.HashMap;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc.LunaChatLogger;
|
||||
import com.github.ucchyocean.lc.LunaChatMode;
|
||||
import com.github.ucchyocean.lc.PluginInterface;
|
||||
import com.github.ucchyocean.lc.channel.ChannelManager;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc3.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc3.LunaChatLogger;
|
||||
import com.github.ucchyocean.lc3.LunaChatMode;
|
||||
import com.github.ucchyocean.lc3.PluginInterface;
|
||||
import com.github.ucchyocean.lc3.channel.ChannelManager;
|
||||
|
||||
import net.md_5.bungee.api.ProxyServer;
|
||||
import net.md_5.bungee.api.plugin.Plugin;
|
||||
@@ -108,7 +108,7 @@ public class LunaChatBungee extends Plugin implements PluginInterface {
|
||||
/**
|
||||
* このプラグインのJarファイル自身を示すFileクラスを返す。
|
||||
* @return Jarファイル
|
||||
* @see com.github.ucchyocean.lc.PluginInterface#getPluginJarFile()
|
||||
* @see com.github.ucchyocean.lc3.PluginInterface#getPluginJarFile()
|
||||
*/
|
||||
@Override
|
||||
public File getPluginJarFile() {
|
||||
@@ -118,7 +118,7 @@ public class LunaChatBungee extends Plugin implements PluginInterface {
|
||||
/**
|
||||
* LunaChatConfigを取得する
|
||||
* @return LunaChatConfig
|
||||
* @see com.github.ucchyocean.lc.PluginInterface#getLunaChatConfig()
|
||||
* @see com.github.ucchyocean.lc3.PluginInterface#getLunaChatConfig()
|
||||
*/
|
||||
@Override
|
||||
public LunaChatConfig getLunaChatConfig() {
|
||||
@@ -128,7 +128,7 @@ public class LunaChatBungee extends Plugin implements PluginInterface {
|
||||
/**
|
||||
* LunaChatAPIを取得する
|
||||
* @return LunaChatAPI
|
||||
* @see com.github.ucchyocean.lc.PluginInterface#getLunaChatAPI()
|
||||
* @see com.github.ucchyocean.lc3.PluginInterface#getLunaChatAPI()
|
||||
*/
|
||||
@Override
|
||||
public LunaChatAPI getLunaChatAPI() {
|
||||
+2
-2
@@ -3,9 +3,9 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.bungee;
|
||||
package com.github.ucchyocean.lc3.bungee;
|
||||
|
||||
import com.github.ucchyocean.lc.command.LunaChatCommandBungee;
|
||||
import com.github.ucchyocean.lc3.command.LunaChatCommandBungee;
|
||||
|
||||
import net.md_5.bungee.api.CommandSender;
|
||||
import net.md_5.bungee.api.plugin.Command;
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.bungee;
|
||||
package com.github.ucchyocean.lc3.bungee;
|
||||
|
||||
import net.md_5.bungee.api.ChatColor;
|
||||
import net.md_5.bungee.api.CommandSender;
|
||||
+5
-5
@@ -3,16 +3,16 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.bungee;
|
||||
package com.github.ucchyocean.lc3.bungee;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.regex.Matcher;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc.Utility;
|
||||
import com.github.ucchyocean.lc.japanize.Japanizer;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc3.Utility;
|
||||
import com.github.ucchyocean.lc3.japanize.Japanizer;
|
||||
|
||||
import net.md_5.bungee.api.ChatColor;
|
||||
import net.md_5.bungee.api.CommandSender;
|
||||
+18
-18
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.channel;
|
||||
package com.github.ucchyocean.lc3.channel;
|
||||
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.ArrayList;
|
||||
@@ -18,20 +18,20 @@ import org.bukkit.Location;
|
||||
import org.bukkit.World;
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc.Messages;
|
||||
import com.github.ucchyocean.lc.NGWordAction;
|
||||
import com.github.ucchyocean.lc.Utility;
|
||||
import com.github.ucchyocean.lc.UtilityBukkit;
|
||||
import com.github.ucchyocean.lc.bridge.DynmapBridge;
|
||||
import com.github.ucchyocean.lc.bukkit.LunaChatBukkit;
|
||||
import com.github.ucchyocean.lc.event.LunaChatChannelChatEvent;
|
||||
import com.github.ucchyocean.lc.event.LunaChatChannelMessageEvent;
|
||||
import com.github.ucchyocean.lc.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc.member.ChannelMemberBukkit;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc3.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc3.Messages;
|
||||
import com.github.ucchyocean.lc3.NGWordAction;
|
||||
import com.github.ucchyocean.lc3.Utility;
|
||||
import com.github.ucchyocean.lc3.UtilityBukkit;
|
||||
import com.github.ucchyocean.lc3.bridge.DynmapBridge;
|
||||
import com.github.ucchyocean.lc3.bukkit.LunaChatBukkit;
|
||||
import com.github.ucchyocean.lc3.event.LunaChatChannelChatEvent;
|
||||
import com.github.ucchyocean.lc3.event.LunaChatChannelMessageEvent;
|
||||
import com.github.ucchyocean.lc3.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMemberBukkit;
|
||||
|
||||
/**
|
||||
* チャンネルの実装クラス
|
||||
@@ -437,7 +437,7 @@ public class BukkitChannel extends Channel {
|
||||
/**
|
||||
* チャンネルのオンライン人数を返す
|
||||
* @return オンライン人数
|
||||
* @see com.github.ucchyocean.lc.channel.Channel#getOnlineNum()
|
||||
* @see com.github.ucchyocean.lc3.channel.Channel#getOnlineNum()
|
||||
*/
|
||||
@Override
|
||||
public int getOnlineNum() {
|
||||
@@ -453,7 +453,7 @@ public class BukkitChannel extends Channel {
|
||||
/**
|
||||
* チャンネルの総参加人数を返す
|
||||
* @return 総参加人数
|
||||
* @see com.github.ucchyocean.lc.channel.Channel#getTotalNum()
|
||||
* @see com.github.ucchyocean.lc3.channel.Channel#getTotalNum()
|
||||
*/
|
||||
@Override
|
||||
public int getTotalNum() {
|
||||
@@ -469,7 +469,7 @@ public class BukkitChannel extends Channel {
|
||||
/**
|
||||
* チャンネルのメンバーを返す
|
||||
* @return チャンネルのメンバー
|
||||
* @see com.github.ucchyocean.lc.channel.Channel#getMembers()
|
||||
* @see com.github.ucchyocean.lc3.channel.Channel#getMembers()
|
||||
*/
|
||||
@Override
|
||||
public List<ChannelMember> getMembers() {
|
||||
+17
-21
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.channel;
|
||||
package com.github.ucchyocean.lc3.channel;
|
||||
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.ArrayList;
|
||||
@@ -14,21 +14,17 @@ import java.util.Set;
|
||||
import java.util.regex.Matcher;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.ChatColor;
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc.LunaChatLogger;
|
||||
import com.github.ucchyocean.lc.Messages;
|
||||
import com.github.ucchyocean.lc.NGWordAction;
|
||||
import com.github.ucchyocean.lc.Utility;
|
||||
import com.github.ucchyocean.lc.bungee.LunaChatBungee;
|
||||
import com.github.ucchyocean.lc.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc.member.ChannelMemberProxiedPlayer;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc3.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc3.LunaChatLogger;
|
||||
import com.github.ucchyocean.lc3.Messages;
|
||||
import com.github.ucchyocean.lc3.NGWordAction;
|
||||
import com.github.ucchyocean.lc3.Utility;
|
||||
import com.github.ucchyocean.lc3.bungee.LunaChatBungee;
|
||||
import com.github.ucchyocean.lc3.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMemberProxiedPlayer;
|
||||
|
||||
import net.md_5.bungee.api.ProxyServer;
|
||||
import net.md_5.bungee.api.connection.ProxiedPlayer;
|
||||
@@ -330,7 +326,7 @@ public class BungeeChannel extends Channel {
|
||||
// パーミッション lunachat-admin.listen-all-channels を持つプレイヤーを
|
||||
// 受信者に加える。
|
||||
if ( config.isOpListenAllChannel() ) {
|
||||
for ( Player p : Bukkit.getOnlinePlayers() ) {
|
||||
for ( ProxiedPlayer p : ProxyServer.getInstance().getPlayers() ) {
|
||||
ChannelMember cp = ChannelMember.getChannelMember(p);
|
||||
if ( cp.hasPermission("lunachat-admin.listen-all-channels")
|
||||
&& !recipients.contains(cp) ) {
|
||||
@@ -367,7 +363,7 @@ public class BungeeChannel extends Channel {
|
||||
|
||||
// 設定に応じて、コンソールに出力する
|
||||
if ( config.isDisplayChatOnConsole() ) {
|
||||
Bukkit.getLogger().info(ChatColor.stripColor(message));
|
||||
LunaChatBungee.getInstance().getLogger().info(message);
|
||||
}
|
||||
|
||||
// ロギング
|
||||
@@ -377,7 +373,7 @@ public class BungeeChannel extends Channel {
|
||||
/**
|
||||
* チャンネルのオンライン人数を返す
|
||||
* @return オンライン人数
|
||||
* @see com.github.ucchyocean.lc.channel.Channel#getOnlineNum()
|
||||
* @see com.github.ucchyocean.lc3.channel.Channel#getOnlineNum()
|
||||
*/
|
||||
@Override
|
||||
public int getOnlineNum() {
|
||||
@@ -393,7 +389,7 @@ public class BungeeChannel extends Channel {
|
||||
/**
|
||||
* チャンネルの総参加人数を返す
|
||||
* @return 総参加人数
|
||||
* @see com.github.ucchyocean.lc.channel.Channel#getTotalNum()
|
||||
* @see com.github.ucchyocean.lc3.channel.Channel#getTotalNum()
|
||||
*/
|
||||
@Override
|
||||
public int getTotalNum() {
|
||||
@@ -409,7 +405,7 @@ public class BungeeChannel extends Channel {
|
||||
/**
|
||||
* チャンネルのメンバーを返す
|
||||
* @return チャンネルのメンバー
|
||||
* @see com.github.ucchyocean.lc.channel.Channel#getMembers()
|
||||
* @see com.github.ucchyocean.lc3.channel.Channel#getMembers()
|
||||
*/
|
||||
@Override
|
||||
public List<ChannelMember> getMembers() {
|
||||
+22
-14
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.channel;
|
||||
package com.github.ucchyocean.lc3.channel;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.FilenameFilter;
|
||||
@@ -15,14 +15,15 @@ import java.util.Map;
|
||||
|
||||
import org.bukkit.ChatColor;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc.LunaChatLogger;
|
||||
import com.github.ucchyocean.lc.Messages;
|
||||
import com.github.ucchyocean.lc.YamlConfig;
|
||||
import com.github.ucchyocean.lc.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc3.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc3.LunaChatLogger;
|
||||
import com.github.ucchyocean.lc3.LunaChatMode;
|
||||
import com.github.ucchyocean.lc3.Messages;
|
||||
import com.github.ucchyocean.lc3.YamlConfig;
|
||||
import com.github.ucchyocean.lc3.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* チャンネル
|
||||
@@ -170,7 +171,6 @@ public abstract class Channel {
|
||||
this.muteExpires = new HashMap<ChannelMember, Long>();
|
||||
this.privateMessageTo = "";
|
||||
this.allowcc = true;
|
||||
this.japanizeType = null;
|
||||
|
||||
LunaChatConfig config = LunaChat.getConfig();
|
||||
if ( isPersonalChat() ) {
|
||||
@@ -178,6 +178,7 @@ public abstract class Channel {
|
||||
} else {
|
||||
this.format = config.getDefaultFormat();
|
||||
}
|
||||
this.japanizeType = config.getJapanizeType();
|
||||
|
||||
logger = new LunaChatLogger(name.replace(">", "-"));
|
||||
}
|
||||
@@ -661,7 +662,14 @@ public abstract class Channel {
|
||||
return null;
|
||||
}
|
||||
|
||||
Channel channel = new BukkitChannel(name);
|
||||
Channel channel = null;
|
||||
if ( LunaChat.getMode() == LunaChatMode.BUKKIT ) {
|
||||
channel = new BukkitChannel(name);
|
||||
} else if ( LunaChat.getMode() == LunaChatMode.BUNGEE ) {
|
||||
channel = new BungeeChannel(name);
|
||||
}
|
||||
// TODO Standalone のチャンネル作成
|
||||
|
||||
channel.alias = castWithDefault(data.get(KEY_ALIAS), "");
|
||||
channel.description = castWithDefault(data.get(KEY_DESC), "");
|
||||
channel.format = castWithDefault(data.get(KEY_FORMAT), channel.format);
|
||||
@@ -1029,9 +1037,9 @@ public abstract class Channel {
|
||||
*/
|
||||
private static List<String> getStringList(List<ChannelMember> org) {
|
||||
|
||||
ArrayList<String> result = new ArrayList<String>();
|
||||
List<String> result = new ArrayList<String>();
|
||||
for ( ChannelMember cp : org ) {
|
||||
result.add(cp.toString());
|
||||
if ( cp != null ) result.add(cp.toString());
|
||||
}
|
||||
return result;
|
||||
}
|
||||
@@ -1045,7 +1053,7 @@ public abstract class Channel {
|
||||
|
||||
HashMap<String, Long> result = new HashMap<String, Long>();
|
||||
for ( ChannelMember cp : org.keySet() ) {
|
||||
result.put(cp.toString(), org.get(cp));
|
||||
if ( cp != null ) result.put(cp.toString(), org.get(cp));
|
||||
}
|
||||
return result;
|
||||
}
|
||||
+20
-20
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.channel;
|
||||
package com.github.ucchyocean.lc3.channel;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
@@ -12,13 +12,13 @@ import java.util.Collection;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc.LunaChatMode;
|
||||
import com.github.ucchyocean.lc.Messages;
|
||||
import com.github.ucchyocean.lc.YamlConfig;
|
||||
import com.github.ucchyocean.lc.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc3.LunaChatMode;
|
||||
import com.github.ucchyocean.lc3.Messages;
|
||||
import com.github.ucchyocean.lc3.YamlConfig;
|
||||
import com.github.ucchyocean.lc3.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* チャンネルマネージャー
|
||||
@@ -271,7 +271,7 @@ public class ChannelManager implements LunaChatAPI {
|
||||
* 指定したチャンネル名が存在するかどうかを返す
|
||||
* @param channelName チャンネル名
|
||||
* @return 存在するかどうか
|
||||
* @see com.github.ucchyocean.lc.LunaChatAPI#isExistChannel(java.lang.String)
|
||||
* @see com.github.ucchyocean.lc3.LunaChatAPI#isExistChannel(java.lang.String)
|
||||
*/
|
||||
@Override
|
||||
public boolean isExistChannel(String channelName) {
|
||||
@@ -284,7 +284,7 @@ public class ChannelManager implements LunaChatAPI {
|
||||
/**
|
||||
* 全てのチャンネルを返す
|
||||
* @return 全てのチャンネル
|
||||
* @see com.github.ucchyocean.lc.LunaChatAPI#getChannels()
|
||||
* @see com.github.ucchyocean.lc3.LunaChatAPI#getChannels()
|
||||
*/
|
||||
@Override
|
||||
public Collection<Channel> getChannels() {
|
||||
@@ -296,7 +296,7 @@ public class ChannelManager implements LunaChatAPI {
|
||||
* プレイヤーが参加しているチャンネルを返す
|
||||
* @param playerName プレイヤー名
|
||||
* @return チャンネル
|
||||
* @see com.github.ucchyocean.lc.LunaChatAPI#getChannelsByPlayer(java.lang.String)
|
||||
* @see com.github.ucchyocean.lc3.LunaChatAPI#getChannelsByPlayer(java.lang.String)
|
||||
*/
|
||||
@Override
|
||||
public Collection<Channel> getChannelsByPlayer(String playerName) {
|
||||
@@ -317,7 +317,7 @@ public class ChannelManager implements LunaChatAPI {
|
||||
* プレイヤーが参加しているデフォルトのチャンネルを返す
|
||||
* @param playerName プレイヤー
|
||||
* @return チャンネル
|
||||
* @see com.github.ucchyocean.lc.LunaChatAPI#getDefaultChannel(java.lang.String)
|
||||
* @see com.github.ucchyocean.lc3.LunaChatAPI#getDefaultChannel(java.lang.String)
|
||||
*/
|
||||
@Override
|
||||
public Channel getDefaultChannel(String playerName) {
|
||||
@@ -334,7 +334,7 @@ public class ChannelManager implements LunaChatAPI {
|
||||
* プレイヤーのデフォルトチャンネルを設定する
|
||||
* @param playerName プレイヤー
|
||||
* @param channelName チャンネル名
|
||||
* @see com.github.ucchyocean.lc.LunaChatAPI#setDefaultChannel(java.lang.String, java.lang.String)
|
||||
* @see com.github.ucchyocean.lc3.LunaChatAPI#setDefaultChannel(java.lang.String, java.lang.String)
|
||||
*/
|
||||
@Override
|
||||
public void setDefaultChannel(String playerName, String channelName) {
|
||||
@@ -349,7 +349,7 @@ public class ChannelManager implements LunaChatAPI {
|
||||
/**
|
||||
* 指定した名前のプレイヤーに設定されている、デフォルトチャンネルを削除する
|
||||
* @param playerName プレイヤー名
|
||||
* @see com.github.ucchyocean.lc.LunaChatAPI#removeDefaultChannel(java.lang.String)
|
||||
* @see com.github.ucchyocean.lc3.LunaChatAPI#removeDefaultChannel(java.lang.String)
|
||||
*/
|
||||
@Override
|
||||
public void removeDefaultChannel(String playerName) {
|
||||
@@ -363,7 +363,7 @@ public class ChannelManager implements LunaChatAPI {
|
||||
* チャンネルを取得する
|
||||
* @param channelName チャンネル名、または、チャンネルの別名
|
||||
* @return チャンネル
|
||||
* @see com.github.ucchyocean.lc.LunaChatAPI#getChannel(java.lang.String)
|
||||
* @see com.github.ucchyocean.lc3.LunaChatAPI#getChannel(java.lang.String)
|
||||
*/
|
||||
@Override
|
||||
public Channel getChannel(String channelName) {
|
||||
@@ -384,7 +384,7 @@ public class ChannelManager implements LunaChatAPI {
|
||||
* 新しいチャンネルを作成する
|
||||
* @param channelName チャンネル名
|
||||
* @return 作成されたチャンネル
|
||||
* @see com.github.ucchyocean.lc.LunaChatAPI#createChannel(java.lang.String)
|
||||
* @see com.github.ucchyocean.lc3.LunaChatAPI#createChannel(java.lang.String)
|
||||
*/
|
||||
@Override
|
||||
public Channel createChannel(String channelName) {
|
||||
@@ -416,7 +416,7 @@ public class ChannelManager implements LunaChatAPI {
|
||||
* チャンネルを削除する
|
||||
* @param channelName 削除するチャンネル名
|
||||
* @return 削除したかどうか
|
||||
* @see com.github.ucchyocean.lc.LunaChatAPI#removeChannel(java.lang.String)
|
||||
* @see com.github.ucchyocean.lc3.LunaChatAPI#removeChannel(java.lang.String)
|
||||
*/
|
||||
@Override
|
||||
public boolean removeChannel(String channelName) {
|
||||
@@ -456,7 +456,7 @@ public class ChannelManager implements LunaChatAPI {
|
||||
* テンプレートを取得する
|
||||
* @param id テンプレートID
|
||||
* @return テンプレート
|
||||
* @see com.github.ucchyocean.lc.LunaChatAPI#getTemplate(java.lang.String)
|
||||
* @see com.github.ucchyocean.lc3.LunaChatAPI#getTemplate(java.lang.String)
|
||||
*/
|
||||
@Override
|
||||
public String getTemplate(String id) {
|
||||
@@ -467,7 +467,7 @@ public class ChannelManager implements LunaChatAPI {
|
||||
* テンプレートを登録する
|
||||
* @param id テンプレートID
|
||||
* @param template テンプレート
|
||||
* @see com.github.ucchyocean.lc.LunaChatAPI#setTemplate(java.lang.String, java.lang.String)
|
||||
* @see com.github.ucchyocean.lc3.LunaChatAPI#setTemplate(java.lang.String, java.lang.String)
|
||||
*/
|
||||
@Override
|
||||
public void setTemplate(String id, String template) {
|
||||
@@ -478,7 +478,7 @@ public class ChannelManager implements LunaChatAPI {
|
||||
/**
|
||||
* テンプレートを削除する
|
||||
* @param id テンプレートID
|
||||
* @see com.github.ucchyocean.lc.LunaChatAPI#removeTemplate(java.lang.String)
|
||||
* @see com.github.ucchyocean.lc3.LunaChatAPI#removeTemplate(java.lang.String)
|
||||
*/
|
||||
@Override
|
||||
public void removeTemplate(String id) {
|
||||
+3
-3
@@ -3,10 +3,10 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.channel;
|
||||
package com.github.ucchyocean.lc3.channel;
|
||||
|
||||
import com.github.ucchyocean.lc.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* Japanize2行表示のときに、変換結果を遅延してチャンネルに表示するためのタスク
|
||||
+8
-8
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.channel;
|
||||
package com.github.ucchyocean.lc3.channel;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
@@ -14,13 +14,13 @@ import org.bukkit.Bukkit;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.scheduler.BukkitRunnable;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.Utility;
|
||||
import com.github.ucchyocean.lc.event.LunaChatPostJapanizeEvent;
|
||||
import com.github.ucchyocean.lc.japanize.IMEConverter;
|
||||
import com.github.ucchyocean.lc.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc.japanize.YukiKanaConverter;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.Utility;
|
||||
import com.github.ucchyocean.lc3.event.LunaChatPostJapanizeEvent;
|
||||
import com.github.ucchyocean.lc3.japanize.IMEConverter;
|
||||
import com.github.ucchyocean.lc3.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc3.japanize.YukiKanaConverter;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* Japanize変換を実行して、実行後に発言を行うタスク
|
||||
+6
-6
@@ -3,17 +3,17 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.channel;
|
||||
package com.github.ucchyocean.lc3.channel;
|
||||
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.event.player.AsyncPlayerChatEvent;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.bukkit.LunaChatBukkit;
|
||||
import com.github.ucchyocean.lc.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc.member.ChannelMemberPlayer;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.bukkit.LunaChatBukkit;
|
||||
import com.github.ucchyocean.lc3.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMemberPlayer;
|
||||
|
||||
/**
|
||||
* Japanize2行表示のときに、変換結果を遅延して通常チャットに表示するためのタスク
|
||||
+3
-3
@@ -3,15 +3,15 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.channel;
|
||||
package com.github.ucchyocean.lc3.channel;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
import com.github.ucchyocean.lc.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* Japanize2行表示のときに、変換結果を遅延して指定した受信者に表示するためのタスク。
|
||||
+3
-4
@@ -3,10 +3,10 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.channel;
|
||||
package com.github.ucchyocean.lc3.channel;
|
||||
|
||||
import com.github.ucchyocean.lc.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* Japanize2行表示のときに、変換結果を遅延してチャンネルに表示するためのタスク
|
||||
@@ -49,5 +49,4 @@ public class JapanizeChannelChatTask implements Runnable {
|
||||
channel.sendMessage(player, task.getResult(), lineFormat, true, name);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
+6
-6
@@ -3,18 +3,18 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.channel;
|
||||
package com.github.ucchyocean.lc3.channel;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.regex.Matcher;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.Utility;
|
||||
import com.github.ucchyocean.lc.japanize.IMEConverter;
|
||||
import com.github.ucchyocean.lc.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc.japanize.YukiKanaConverter;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.Utility;
|
||||
import com.github.ucchyocean.lc3.japanize.IMEConverter;
|
||||
import com.github.ucchyocean.lc3.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc3.japanize.YukiKanaConverter;
|
||||
|
||||
/**
|
||||
* Japanize変換を実行して、実行後に発言を行うタスク
|
||||
+8
-8
@@ -3,10 +3,10 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* acceptコマンドの実行クラス
|
||||
@@ -21,7 +21,7 @@ public class AcceptCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -31,7 +31,7 @@ public class AcceptCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -41,7 +41,7 @@ public class AcceptCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -52,7 +52,7 @@ public class AcceptCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -66,7 +66,7 @@ public class AcceptCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(ChannelMember sender, String label, String[] args) {
|
||||
+8
-8
@@ -3,10 +3,10 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* banコマンドの実行クラス
|
||||
@@ -22,7 +22,7 @@ public class BanCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -32,7 +32,7 @@ public class BanCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -42,7 +42,7 @@ public class BanCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -53,7 +53,7 @@ public class BanCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -68,7 +68,7 @@ public class BanCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(
|
||||
+8
-8
@@ -3,10 +3,10 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* createコマンドの実行クラス
|
||||
@@ -21,7 +21,7 @@ public class CreateCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -31,7 +31,7 @@ public class CreateCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -41,7 +41,7 @@ public class CreateCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -52,7 +52,7 @@ public class CreateCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -66,7 +66,7 @@ public class CreateCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import java.util.HashMap;
|
||||
|
||||
+7
-7
@@ -3,9 +3,9 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* denyコマンドの実行クラス
|
||||
@@ -20,7 +20,7 @@ public class DenyCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -30,7 +30,7 @@ public class DenyCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -40,7 +40,7 @@ public class DenyCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -51,7 +51,7 @@ public class DenyCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -65,7 +65,7 @@ public class DenyCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(ChannelMember sender, String label, String[] args) {
|
||||
+4
-4
@@ -3,9 +3,9 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* dictionaryコマンドのエイリアス実行クラス、名前のみが異なるが、他は全て一緒。
|
||||
@@ -19,7 +19,7 @@ public class DicCommand extends DictionaryCommand {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -30,7 +30,7 @@ public class DicCommand extends DictionaryCommand {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
+8
-9
@@ -3,13 +3,12 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import java.util.HashMap;
|
||||
|
||||
import org.bukkit.ChatColor;
|
||||
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.ChatColor;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* dictionaryコマンドの実行クラス
|
||||
@@ -24,7 +23,7 @@ public class DictionaryCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -34,7 +33,7 @@ public class DictionaryCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -44,7 +43,7 @@ public class DictionaryCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -55,7 +54,7 @@ public class DictionaryCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -69,7 +68,7 @@ public class DictionaryCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(ChannelMember sender, String label, String[] args) {
|
||||
+8
-8
@@ -3,12 +3,12 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* formatコマンドの実行クラス
|
||||
@@ -23,7 +23,7 @@ public class FormatCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -33,7 +33,7 @@ public class FormatCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -43,7 +43,7 @@ public class FormatCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -54,7 +54,7 @@ public class FormatCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -68,7 +68,7 @@ public class FormatCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(
|
||||
+7
-7
@@ -3,11 +3,11 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* helpコマンドの実行クラス
|
||||
@@ -35,7 +35,7 @@ public class HelpCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -45,7 +45,7 @@ public class HelpCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -55,7 +55,7 @@ public class HelpCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -66,7 +66,7 @@ public class HelpCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -80,7 +80,7 @@ public class HelpCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(ChannelMember sender, String label, String[] args) {
|
||||
+10
-10
@@ -3,14 +3,14 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
import com.github.ucchyocean.lc.Messages;
|
||||
import com.github.ucchyocean.lc.Utility;
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.Messages;
|
||||
import com.github.ucchyocean.lc3.Utility;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* hideコマンドの実行クラス
|
||||
@@ -33,7 +33,7 @@ public class HideCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -43,7 +43,7 @@ public class HideCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -53,7 +53,7 @@ public class HideCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -64,7 +64,7 @@ public class HideCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -79,7 +79,7 @@ public class HideCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(
|
||||
+8
-8
@@ -3,12 +3,12 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* infoコマンドの実行クラス
|
||||
@@ -23,7 +23,7 @@ public class InfoCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -33,7 +33,7 @@ public class InfoCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -43,7 +43,7 @@ public class InfoCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -54,7 +54,7 @@ public class InfoCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -68,7 +68,7 @@ public class InfoCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(
|
||||
+8
-8
@@ -3,10 +3,10 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* inviteコマンドの実行クラス
|
||||
@@ -24,7 +24,7 @@ public class InviteCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -34,7 +34,7 @@ public class InviteCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -44,7 +44,7 @@ public class InviteCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -55,7 +55,7 @@ public class InviteCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -69,7 +69,7 @@ public class InviteCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(ChannelMember sender, String label, String[] args) {
|
||||
+8
-8
@@ -3,10 +3,10 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* joinコマンドの実行クラス
|
||||
@@ -22,7 +22,7 @@ public class JoinCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -32,7 +32,7 @@ public class JoinCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -42,7 +42,7 @@ public class JoinCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -53,7 +53,7 @@ public class JoinCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -67,7 +67,7 @@ public class JoinCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(
|
||||
+10
-13
@@ -3,12 +3,10 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* kickコマンドの実行クラス
|
||||
@@ -23,7 +21,7 @@ public class KickCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -33,7 +31,7 @@ public class KickCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -43,7 +41,7 @@ public class KickCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -54,7 +52,7 @@ public class KickCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -68,7 +66,7 @@ public class KickCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(
|
||||
@@ -87,9 +85,8 @@ public class KickCommand extends SubCommandAbst {
|
||||
Channel channel = null;
|
||||
if (args.length >= 3) {
|
||||
channel = api.getChannel(args[2]);
|
||||
} else if (sender instanceof Player) {
|
||||
Player kicker = (Player) sender;
|
||||
channel = api.getDefaultChannel(kicker.getName());
|
||||
} else {
|
||||
channel = api.getDefaultChannel(sender.getName());
|
||||
}
|
||||
if (channel == null) {
|
||||
sendResourceMessage(sender, PREERR, "errmsgNoJoin");
|
||||
+8
-8
@@ -3,10 +3,10 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* leaveコマンドの実行クラス
|
||||
@@ -21,7 +21,7 @@ public class LeaveCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -31,7 +31,7 @@ public class LeaveCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -41,7 +41,7 @@ public class LeaveCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -52,7 +52,7 @@ public class LeaveCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -66,7 +66,7 @@ public class LeaveCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(
|
||||
+10
-11
@@ -3,17 +3,16 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
||||
import java.util.Comparator;
|
||||
|
||||
import org.bukkit.ChatColor;
|
||||
|
||||
import com.github.ucchyocean.lc.Messages;
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.ChatColor;
|
||||
import com.github.ucchyocean.lc3.Messages;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* listコマンドの実行クラス
|
||||
@@ -35,7 +34,7 @@ public class ListCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -45,7 +44,7 @@ public class ListCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -55,7 +54,7 @@ public class ListCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -66,7 +65,7 @@ public class ListCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -80,7 +79,7 @@ public class ListCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(
|
||||
+11
-11
@@ -3,15 +3,15 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChatLogger;
|
||||
import com.github.ucchyocean.lc.Messages;
|
||||
import com.github.ucchyocean.lc.bukkit.LunaChatBukkit;
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.LunaChatLogger;
|
||||
import com.github.ucchyocean.lc3.Messages;
|
||||
import com.github.ucchyocean.lc3.bukkit.LunaChatBukkit;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* logコマンドの実行クラス
|
||||
@@ -30,7 +30,7 @@ public class LogCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -40,7 +40,7 @@ public class LogCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -50,7 +50,7 @@ public class LogCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -61,7 +61,7 @@ public class LogCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -75,7 +75,7 @@ public class LogCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(ChannelMember sender, String label, String[] args) {
|
||||
+6
-6
@@ -3,15 +3,15 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.Messages;
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.Messages;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* Lunachatコマンドの処理クラス
|
||||
@@ -303,7 +303,7 @@ public abstract class LunaChatCommand {
|
||||
return items;
|
||||
|
||||
}
|
||||
return null;
|
||||
return new ArrayList<String>();
|
||||
}
|
||||
|
||||
/**
|
||||
+3
-3
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
@@ -14,7 +14,7 @@ import org.bukkit.command.CommandExecutor;
|
||||
import org.bukkit.command.CommandSender;
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* Lunachatコマンドの処理クラス(Bukkit実装)
|
||||
@@ -52,7 +52,7 @@ public class LunaChatCommandBukkit extends LunaChatCommand implements CommandExe
|
||||
* オンラインプレイヤーのうち、プレイヤー名が指定された文字列と前方一致するものをリストにして返す
|
||||
* @param pre 検索キー
|
||||
* @return プレイヤー名リスト
|
||||
* @see com.github.ucchyocean.lc.command.LunaChatCommand#getListPlayerNames(java.lang.String)
|
||||
* @see com.github.ucchyocean.lc3.command.LunaChatCommand#getListPlayerNames(java.lang.String)
|
||||
*/
|
||||
@Override
|
||||
protected List<String> getListPlayerNames(String pre) {
|
||||
+5
-6
@@ -3,12 +3,12 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
import net.md_5.bungee.api.CommandSender;
|
||||
import net.md_5.bungee.api.ProxyServer;
|
||||
@@ -27,8 +27,7 @@ public class LunaChatCommandBungee extends LunaChatCommand {
|
||||
* @see net.md_5.bungee.api.plugin.Command#execute(net.md_5.bungee.api.CommandSender, java.lang.String[])
|
||||
*/
|
||||
public void execute(CommandSender sender, String[] args) {
|
||||
String label = args.length >= 1 ? args[0] : "lunachat";
|
||||
execute(ChannelMember.getChannelMember(sender), label, args);
|
||||
execute(ChannelMember.getChannelMember(sender), "ch", args);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -39,14 +38,14 @@ public class LunaChatCommandBungee extends LunaChatCommand {
|
||||
* @see net.md_5.bungee.api.plugin.TabExecutor#onTabComplete(net.md_5.bungee.api.CommandSender, java.lang.String[])
|
||||
*/
|
||||
public Iterable<String> onTabComplete(CommandSender sender, String[] args) {
|
||||
return onTabComplete(ChannelMember.getChannelMember(sender), "", args);
|
||||
return onTabComplete(ChannelMember.getChannelMember(sender), "ch", args);
|
||||
}
|
||||
|
||||
/**
|
||||
* オンラインプレイヤーのうち、プレイヤー名が指定された文字列と前方一致するものをリストにして返す
|
||||
* @param pre 検索キー
|
||||
* @return プレイヤー名リスト
|
||||
* @see com.github.ucchyocean.lc.command.LunaChatCommand#getListPlayerNames(java.lang.String)
|
||||
* @see com.github.ucchyocean.lc3.command.LunaChatCommand#getListPlayerNames(java.lang.String)
|
||||
*/
|
||||
@Override
|
||||
protected List<String> getListPlayerNames(String pre) {
|
||||
+5
-5
@@ -3,17 +3,17 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import org.bukkit.command.Command;
|
||||
import org.bukkit.command.CommandExecutor;
|
||||
import org.bukkit.command.CommandSender;
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc.Messages;
|
||||
import com.github.ucchyocean.lc.bukkit.LunaChatBukkit;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc3.Messages;
|
||||
import com.github.ucchyocean.lc3.bukkit.LunaChatBukkit;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* Japanize変換設定コマンド
|
||||
+6
-6
@@ -3,17 +3,17 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import org.bukkit.command.Command;
|
||||
import org.bukkit.command.CommandExecutor;
|
||||
import org.bukkit.command.CommandSender;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc.Messages;
|
||||
import com.github.ucchyocean.lc.bukkit.LunaChatBukkit;
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc3.Messages;
|
||||
import com.github.ucchyocean.lc3.bukkit.LunaChatBukkit;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* 1:1チャット送信コマンド
|
||||
+3
-3
@@ -3,13 +3,13 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import org.bukkit.command.Command;
|
||||
import org.bukkit.command.CommandSender;
|
||||
|
||||
import com.github.ucchyocean.lc.Messages;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.Messages;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* 1:1チャット受信コマンド
|
||||
+4
-4
@@ -3,9 +3,9 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* moderatorコマンドのエイリアス実行クラス、名前のみが異なるが、他は全て一緒。
|
||||
@@ -19,7 +19,7 @@ public class ModCommand extends ModeratorCommand {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -30,7 +30,7 @@ public class ModCommand extends ModeratorCommand {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者O
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
+8
-8
@@ -3,12 +3,12 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* moderatorコマンドの実行クラス
|
||||
@@ -23,7 +23,7 @@ public class ModeratorCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -33,7 +33,7 @@ public class ModeratorCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -43,7 +43,7 @@ public class ModeratorCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -54,7 +54,7 @@ public class ModeratorCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -68,7 +68,7 @@ public class ModeratorCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(
|
||||
+9
-11
@@ -3,12 +3,10 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* muteコマンドの実行クラス
|
||||
@@ -24,7 +22,7 @@ public class MuteCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -34,7 +32,7 @@ public class MuteCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -44,7 +42,7 @@ public class MuteCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -55,7 +53,7 @@ public class MuteCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -70,7 +68,7 @@ public class MuteCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(
|
||||
@@ -91,7 +89,7 @@ public class MuteCommand extends SubCommandAbst {
|
||||
if (args.length >= 3) {
|
||||
channel = api.getChannel(args[2]);
|
||||
isSpecifiedChannel = true;
|
||||
} else if (sender instanceof Player) {
|
||||
} else {
|
||||
channel = api.getDefaultChannel(sender.getName());
|
||||
}
|
||||
if (channel == null) {
|
||||
+11
-11
@@ -3,16 +3,16 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
|
||||
import com.github.ucchyocean.lc.Utility;
|
||||
import com.github.ucchyocean.lc.UtilityBukkit;
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.Utility;
|
||||
import com.github.ucchyocean.lc3.UtilityBukkit;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.japanize.JapanizeType;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* optionコマンドの実行クラス
|
||||
@@ -31,7 +31,7 @@ public class OptionCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -41,7 +41,7 @@ public class OptionCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -51,7 +51,7 @@ public class OptionCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -62,7 +62,7 @@ public class OptionCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -76,7 +76,7 @@ public class OptionCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(
|
||||
+9
-11
@@ -3,12 +3,10 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* pardonコマンドの実行クラス
|
||||
@@ -23,7 +21,7 @@ public class PardonCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -33,7 +31,7 @@ public class PardonCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -43,7 +41,7 @@ public class PardonCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -54,7 +52,7 @@ public class PardonCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -68,7 +66,7 @@ public class PardonCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(
|
||||
@@ -87,7 +85,7 @@ public class PardonCommand extends SubCommandAbst {
|
||||
Channel channel = null;
|
||||
if (args.length >= 3) {
|
||||
channel = api.getChannel(args[2]);
|
||||
} else if (sender instanceof Player) {
|
||||
} else {
|
||||
channel = api.getDefaultChannel(sender.getName());
|
||||
}
|
||||
if (channel == null) {
|
||||
+8
-8
@@ -3,10 +3,10 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* reloadコマンドの実行クラス
|
||||
@@ -21,7 +21,7 @@ public class ReloadCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -31,7 +31,7 @@ public class ReloadCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -41,7 +41,7 @@ public class ReloadCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -52,7 +52,7 @@ public class ReloadCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -66,7 +66,7 @@ public class ReloadCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(
|
||||
+8
-8
@@ -3,10 +3,10 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* removeコマンドの実行クラス
|
||||
@@ -21,7 +21,7 @@ public class RemoveCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -31,7 +31,7 @@ public class RemoveCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -41,7 +41,7 @@ public class RemoveCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -52,7 +52,7 @@ public class RemoveCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -66,7 +66,7 @@ public class RemoveCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(
|
||||
+8
-8
@@ -1,7 +1,7 @@
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
public class SetCommand extends SubCommandAbst {
|
||||
|
||||
@@ -12,7 +12,7 @@ public class SetCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -22,7 +22,7 @@ public class SetCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -32,7 +32,7 @@ public class SetCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -43,7 +43,7 @@ public class SetCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(ChannelMember sender, String label) {
|
||||
@@ -56,7 +56,7 @@ public class SetCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(ChannelMember sender, String label, String[] args) {
|
||||
+8
-8
@@ -3,15 +3,15 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc.Messages;
|
||||
import com.github.ucchyocean.lc.Utility;
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc3.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc3.Messages;
|
||||
import com.github.ucchyocean.lc3.Utility;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* サブコマンドの抽象クラス
|
||||
+7
-7
@@ -3,9 +3,9 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* templateコマンドの実行クラス
|
||||
@@ -20,7 +20,7 @@ public class TemplateCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -30,7 +30,7 @@ public class TemplateCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -40,7 +40,7 @@ public class TemplateCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -51,7 +51,7 @@ public class TemplateCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -65,7 +65,7 @@ public class TemplateCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(
|
||||
+9
-9
@@ -3,11 +3,11 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import com.github.ucchyocean.lc.Utility;
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.Utility;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* unhideコマンドの実行クラス
|
||||
@@ -23,7 +23,7 @@ public class UnhideCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -33,7 +33,7 @@ public class UnhideCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -43,7 +43,7 @@ public class UnhideCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -54,7 +54,7 @@ public class UnhideCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -69,7 +69,7 @@ public class UnhideCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(
|
||||
+9
-11
@@ -3,12 +3,10 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.command;
|
||||
package com.github.ucchyocean.lc3.command;
|
||||
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* unmuteコマンドの実行クラス
|
||||
@@ -23,7 +21,7 @@ public class UnmuteCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドを取得します。
|
||||
* @return コマンド
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandName()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandName()
|
||||
*/
|
||||
@Override
|
||||
public String getCommandName() {
|
||||
@@ -33,7 +31,7 @@ public class UnmuteCommand extends SubCommandAbst {
|
||||
/**
|
||||
* パーミッションノードを取得します。
|
||||
* @return パーミッションノード
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getPermissionNode()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getPermissionNode()
|
||||
*/
|
||||
@Override
|
||||
public String getPermissionNode() {
|
||||
@@ -43,7 +41,7 @@ public class UnmuteCommand extends SubCommandAbst {
|
||||
/**
|
||||
* コマンドの種別を取得します。
|
||||
* @return コマンド種別
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#getCommandType()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#getCommandType()
|
||||
*/
|
||||
@Override
|
||||
public CommandType getCommandType() {
|
||||
@@ -54,7 +52,7 @@ public class UnmuteCommand extends SubCommandAbst {
|
||||
* 使用方法に関するメッセージをsenderに送信します。
|
||||
* @param sender コマンド実行者
|
||||
* @param label 実行ラベル
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#sendUsageMessage()
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#sendUsageMessage()
|
||||
*/
|
||||
@Override
|
||||
public void sendUsageMessage(
|
||||
@@ -68,7 +66,7 @@ public class UnmuteCommand extends SubCommandAbst {
|
||||
* @param label 実行ラベル
|
||||
* @param args 実行時の引数
|
||||
* @return コマンドが実行されたかどうか
|
||||
* @see com.github.ucchyocean.lc.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
* @see com.github.ucchyocean.lc3.command.SubCommandAbst#runCommand(java.lang.String[])
|
||||
*/
|
||||
@Override
|
||||
public boolean runCommand(
|
||||
@@ -87,7 +85,7 @@ public class UnmuteCommand extends SubCommandAbst {
|
||||
Channel channel = null;
|
||||
if (args.length >= 3) {
|
||||
channel = api.getChannel(args[2]);
|
||||
} else if (sender instanceof Player) {
|
||||
} else {
|
||||
channel = api.getDefaultChannel(sender.getName());
|
||||
}
|
||||
if (channel == null) {
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.event;
|
||||
package com.github.ucchyocean.lc3.event;
|
||||
|
||||
import org.bukkit.event.Cancellable;
|
||||
|
||||
+3
-3
@@ -3,14 +3,14 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.event;
|
||||
package com.github.ucchyocean.lc3.event;
|
||||
|
||||
import org.bukkit.Bukkit;
|
||||
import org.bukkit.event.Event;
|
||||
import org.bukkit.event.HandlerList;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
|
||||
/**
|
||||
* 基底イベントクラス
|
||||
+2
-2
@@ -3,9 +3,9 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.event;
|
||||
package com.github.ucchyocean.lc3.event;
|
||||
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* チャンネルチャットのチャットイベント
|
||||
+3
-3
@@ -3,11 +3,11 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.event;
|
||||
package com.github.ucchyocean.lc3.event;
|
||||
|
||||
import org.bukkit.command.CommandSender;
|
||||
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
|
||||
/**
|
||||
* チャンネル作成イベント
|
||||
@@ -41,7 +41,7 @@ public class LunaChatChannelCreateEvent extends LunaChatBaseCancellableEvent {
|
||||
/**
|
||||
* @deprecated チャンネル作成イベントは、チャンネルを作成する前に呼び出されるので、
|
||||
* このメソッドの戻り値は必ずnullになります。
|
||||
* @see com.github.ucchyocean.lc.event.LunaChatBaseEvent#getChannel()
|
||||
* @see com.github.ucchyocean.lc3.event.LunaChatBaseEvent#getChannel()
|
||||
*/
|
||||
@Override
|
||||
public Channel getChannel() {
|
||||
+2
-2
@@ -3,11 +3,11 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.event;
|
||||
package com.github.ucchyocean.lc3.event;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* メンバー変更イベント
|
||||
+2
-2
@@ -3,11 +3,11 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.event;
|
||||
package com.github.ucchyocean.lc3.event;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* チャンネルチャットのメッセージイベント、
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.event;
|
||||
package com.github.ucchyocean.lc3.event;
|
||||
|
||||
import java.util.HashMap;
|
||||
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.event;
|
||||
package com.github.ucchyocean.lc3.event;
|
||||
|
||||
import org.bukkit.command.CommandSender;
|
||||
|
||||
+2
-2
@@ -3,9 +3,9 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.event;
|
||||
package com.github.ucchyocean.lc3.event;
|
||||
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* Japanize変換が行われた後に呼び出されるイベント
|
||||
+3
-3
@@ -3,10 +3,10 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.event;
|
||||
package com.github.ucchyocean.lc3.event;
|
||||
|
||||
import com.github.ucchyocean.lc.channel.Channel;
|
||||
import com.github.ucchyocean.lc.member.ChannelMember;
|
||||
import com.github.ucchyocean.lc3.channel.Channel;
|
||||
import com.github.ucchyocean.lc3.member.ChannelMember;
|
||||
|
||||
/**
|
||||
* チャンネルチャットへの発言前に発生するイベント
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
package com.github.ucchyocean.lc.japanize;
|
||||
package com.github.ucchyocean.lc3.japanize;
|
||||
|
||||
import com.google.gson.Gson;
|
||||
import com.google.gson.JsonArray;
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.japanize;
|
||||
package com.github.ucchyocean.lc3.japanize;
|
||||
|
||||
import java.io.BufferedReader;
|
||||
import java.io.IOException;
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
package com.github.ucchyocean.lc.japanize;
|
||||
package com.github.ucchyocean.lc3.japanize;
|
||||
|
||||
/**
|
||||
* 日本語変換タイプ
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2014
|
||||
*/
|
||||
package com.github.ucchyocean.lc.japanize;
|
||||
package com.github.ucchyocean.lc3.japanize;
|
||||
|
||||
import java.util.HashMap;
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
package com.github.ucchyocean.lc.japanize;
|
||||
package com.github.ucchyocean.lc3.japanize;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
+3
-3
@@ -3,10 +3,10 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.member;
|
||||
package com.github.ucchyocean.lc3.member;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.LunaChatMode;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.LunaChatMode;
|
||||
|
||||
/**
|
||||
* チャンネルメンバーの抽象クラス
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.member;
|
||||
package com.github.ucchyocean.lc3.member;
|
||||
|
||||
import org.bukkit.Location;
|
||||
import org.bukkit.World;
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.member;
|
||||
package com.github.ucchyocean.lc3.member;
|
||||
|
||||
import org.bukkit.Location;
|
||||
import org.bukkit.World;
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.member;
|
||||
package com.github.ucchyocean.lc3.member;
|
||||
|
||||
import org.bukkit.Location;
|
||||
import org.bukkit.World;
|
||||
+1
-1
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.member;
|
||||
package com.github.ucchyocean.lc3.member;
|
||||
|
||||
import net.md_5.bungee.api.CommandSender;
|
||||
import net.md_5.bungee.api.connection.ProxiedPlayer;
|
||||
+13
-13
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.member;
|
||||
package com.github.ucchyocean.lc3.member;
|
||||
|
||||
import net.md_5.bungee.api.CommandSender;
|
||||
import net.md_5.bungee.api.chat.TextComponent;
|
||||
@@ -29,7 +29,7 @@ public class ChannelMemberBungeeConsole extends ChannelMemberBungee {
|
||||
/**
|
||||
* BungeeのProxiedPlayerを取得する
|
||||
* @return 常にnullが返される
|
||||
* @see com.github.ucchyocean.lc.member.ChannelMemberBungee#getPlayer()
|
||||
* @see com.github.ucchyocean.lc3.member.ChannelMemberBungee#getPlayer()
|
||||
*/
|
||||
@Override
|
||||
public ProxiedPlayer getPlayer() {
|
||||
@@ -39,7 +39,7 @@ public class ChannelMemberBungeeConsole extends ChannelMemberBungee {
|
||||
/**
|
||||
* 発言者が今いるサーバーを取得する
|
||||
* @return 常にnullが返される
|
||||
* @see com.github.ucchyocean.lc.member.ChannelMemberBungee#getServer()
|
||||
* @see com.github.ucchyocean.lc3.member.ChannelMemberBungee#getServer()
|
||||
*/
|
||||
@Override
|
||||
public Server getServer() {
|
||||
@@ -49,7 +49,7 @@ public class ChannelMemberBungeeConsole extends ChannelMemberBungee {
|
||||
/**
|
||||
* 発言者がオンラインかどうかを取得する
|
||||
* @return 常にtrueが返される
|
||||
* @see com.github.ucchyocean.lc.member.ChannelMember#isOnline()
|
||||
* @see com.github.ucchyocean.lc3.member.ChannelMember#isOnline()
|
||||
*/
|
||||
@Override
|
||||
public boolean isOnline() {
|
||||
@@ -59,7 +59,7 @@ public class ChannelMemberBungeeConsole extends ChannelMemberBungee {
|
||||
/**
|
||||
* 発言者名を取得する
|
||||
* @return 発言者名
|
||||
* @see com.github.ucchyocean.lc.member.ChannelMember#getName()
|
||||
* @see com.github.ucchyocean.lc3.member.ChannelMember#getName()
|
||||
*/
|
||||
@Override
|
||||
public String getName() {
|
||||
@@ -69,7 +69,7 @@ public class ChannelMemberBungeeConsole extends ChannelMemberBungee {
|
||||
/**
|
||||
* 発言者の表示名を取得する
|
||||
* @return 発言者の表示名
|
||||
* @see com.github.ucchyocean.lc.member.ChannelMember#getDisplayName()
|
||||
* @see com.github.ucchyocean.lc3.member.ChannelMember#getDisplayName()
|
||||
*/
|
||||
@Override
|
||||
public String getDisplayName() {
|
||||
@@ -79,7 +79,7 @@ public class ChannelMemberBungeeConsole extends ChannelMemberBungee {
|
||||
/**
|
||||
* プレフィックスを返す
|
||||
* @return 常に空文字列
|
||||
* @see com.github.ucchyocean.lc.member.ChannelMember#getPrefix()
|
||||
* @see com.github.ucchyocean.lc3.member.ChannelMember#getPrefix()
|
||||
*/
|
||||
@Override
|
||||
public String getPrefix() {
|
||||
@@ -89,7 +89,7 @@ public class ChannelMemberBungeeConsole extends ChannelMemberBungee {
|
||||
/**
|
||||
* サフィックスを返す
|
||||
* @return 常に空文字列
|
||||
* @see com.github.ucchyocean.lc.member.ChannelMember#getSuffix()
|
||||
* @see com.github.ucchyocean.lc3.member.ChannelMember#getSuffix()
|
||||
*/
|
||||
@Override
|
||||
public String getSuffix() {
|
||||
@@ -99,7 +99,7 @@ public class ChannelMemberBungeeConsole extends ChannelMemberBungee {
|
||||
/**
|
||||
* 発言者にメッセージを送信する
|
||||
* @param message メッセージ
|
||||
* @see com.github.ucchyocean.lc.member.ChannelMember#sendMessage(java.lang.String)
|
||||
* @see com.github.ucchyocean.lc3.member.ChannelMember#sendMessage(java.lang.String)
|
||||
*/
|
||||
@Override
|
||||
public void sendMessage(String message) {
|
||||
@@ -109,7 +109,7 @@ public class ChannelMemberBungeeConsole extends ChannelMemberBungee {
|
||||
/**
|
||||
* 発言者が今いるワールド名を返す
|
||||
* @return 常に"-"が返される
|
||||
* @see com.github.ucchyocean.lc.member.ChannelMember#getWorldName()
|
||||
* @see com.github.ucchyocean.lc3.member.ChannelMember#getWorldName()
|
||||
*/
|
||||
@Override
|
||||
public String getWorldName() {
|
||||
@@ -120,7 +120,7 @@ public class ChannelMemberBungeeConsole extends ChannelMemberBungee {
|
||||
* 指定されたパーミッションノードの権限を持っているかどうかを取得する
|
||||
* @param node パーミッションノード
|
||||
* @return 権限を持っているかどうか
|
||||
* @see com.github.ucchyocean.lc.member.ChannelMember#hasPermission(java.lang.String)
|
||||
* @see com.github.ucchyocean.lc3.member.ChannelMember#hasPermission(java.lang.String)
|
||||
*/
|
||||
@Override
|
||||
public boolean hasPermission(String node) {
|
||||
@@ -131,7 +131,7 @@ public class ChannelMemberBungeeConsole extends ChannelMemberBungee {
|
||||
* 指定されたパーミッションノードが定義されているかどうかを取得する
|
||||
* @param node パーミッションノード
|
||||
* @return 定義を持っているかどうか
|
||||
* @see com.github.ucchyocean.lc.member.ChannelMember#isPermissionSet(java.lang.String)
|
||||
* @see com.github.ucchyocean.lc3.member.ChannelMember#isPermissionSet(java.lang.String)
|
||||
*/
|
||||
@Override
|
||||
public boolean isPermissionSet(String node) {
|
||||
@@ -141,7 +141,7 @@ public class ChannelMemberBungeeConsole extends ChannelMemberBungee {
|
||||
/**
|
||||
* IDを返す
|
||||
* @return 名前をそのまま返す
|
||||
* @see com.github.ucchyocean.lc.member.ChannelMember#toString()
|
||||
* @see com.github.ucchyocean.lc3.member.ChannelMember#toString()
|
||||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
+3
-3
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.member;
|
||||
package com.github.ucchyocean.lc3.member;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
@@ -14,8 +14,8 @@ import org.bukkit.World;
|
||||
import org.bukkit.command.CommandSender;
|
||||
import org.bukkit.entity.Player;
|
||||
|
||||
import com.github.ucchyocean.lc.bridge.VaultChatBridge;
|
||||
import com.github.ucchyocean.lc.bukkit.LunaChatBukkit;
|
||||
import com.github.ucchyocean.lc3.bridge.VaultChatBridge;
|
||||
import com.github.ucchyocean.lc3.bukkit.LunaChatBukkit;
|
||||
|
||||
/**
|
||||
* ChannelMemberのBukkitPlayer実装
|
||||
+3
-3
@@ -3,7 +3,7 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.member;
|
||||
package com.github.ucchyocean.lc3.member;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
@@ -201,7 +201,7 @@ public class ChannelMemberProxiedPlayer extends ChannelMemberBungee {
|
||||
/**
|
||||
* 発言者が今いるサーバーを取得する
|
||||
* @return サーバー
|
||||
* @see com.github.ucchyocean.lc.member.ChannelMemberBungee#getServer()
|
||||
* @see com.github.ucchyocean.lc3.member.ChannelMemberBungee#getServer()
|
||||
*/
|
||||
@Override
|
||||
public @Nullable Server getServer() {
|
||||
@@ -216,7 +216,7 @@ public class ChannelMemberProxiedPlayer extends ChannelMemberBungee {
|
||||
* 指定されたパーミッションノードが定義されているかどうかを取得する
|
||||
* @param node パーミッションノード
|
||||
* @return 定義を持っているかどうか
|
||||
* @see com.github.ucchyocean.lc.member.ChannelMember#isPermissionSet(java.lang.String)
|
||||
* @see com.github.ucchyocean.lc3.member.ChannelMember#isPermissionSet(java.lang.String)
|
||||
*/
|
||||
@Override
|
||||
public boolean isPermissionSet(String node) {
|
||||
+8
-8
@@ -3,18 +3,18 @@
|
||||
* @license LGPLv3
|
||||
* @copyright Copyright ucchy 2020
|
||||
*/
|
||||
package com.github.ucchyocean.lc.standalone;
|
||||
package com.github.ucchyocean.lc3.standalone;
|
||||
|
||||
import java.io.File;
|
||||
import java.net.URISyntaxException;
|
||||
|
||||
import com.github.ucchyocean.lc.LunaChat;
|
||||
import com.github.ucchyocean.lc.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc.LunaChatLogger;
|
||||
import com.github.ucchyocean.lc.LunaChatMode;
|
||||
import com.github.ucchyocean.lc.PluginInterface;
|
||||
import com.github.ucchyocean.lc.channel.ChannelManager;
|
||||
import com.github.ucchyocean.lc3.LunaChat;
|
||||
import com.github.ucchyocean.lc3.LunaChatAPI;
|
||||
import com.github.ucchyocean.lc3.LunaChatConfig;
|
||||
import com.github.ucchyocean.lc3.LunaChatLogger;
|
||||
import com.github.ucchyocean.lc3.LunaChatMode;
|
||||
import com.github.ucchyocean.lc3.PluginInterface;
|
||||
import com.github.ucchyocean.lc3.channel.ChannelManager;
|
||||
|
||||
/**
|
||||
* LunaChatのスタンドアロンサーバー
|
||||
新しいイシューから参照
ユーザーをブロックする