diff options
| author | Sho Sakuma <me@m1sk9.dev> | 2026-02-07 03:59:25 +0900 |
|---|---|---|
| committer | Sho Sakuma <me@m1sk9.dev> | 2026-02-07 04:00:04 +0900 |
| commit | 40c9d18e4747e23977618e17bafcd64cd0ffa6b4 (patch) | |
| tree | 1fe77e8d677471c8a52ee7b28419423f7a25f14a | |
| parent | c7231d496c60ef68907f976427ab1b9c29e3c9f0 (diff) | |
| download | LunaticChat-40c9d18e4747e23977618e17bafcd64cd0ffa6b4.tar.gz LunaticChat-40c9d18e4747e23977618e17bafcd64cd0ffa6b4.tar.bz2 LunaticChat-40c9d18e4747e23977618e17bafcd64cd0ffa6b4.zip | |
docs: Update Cross Server chat
| -rw-r--r-- | CHANGELOG.md | 1 | ||||
| -rw-r--r-- | docs/.vitepress/config/en.ts | 2 | ||||
| -rw-r--r-- | docs/.vitepress/config/ja.ts | 4 | ||||
| -rw-r--r-- | docs/src/en/guide/admin/configuration.md | 56 | ||||
| -rw-r--r-- | docs/src/en/guide/admin/velocity.md | 2 | ||||
| -rw-r--r-- | docs/src/en/index.md | 4 | ||||
| -rw-r--r-- | docs/src/en/reference/commands/lc/settings.md | 7 | ||||
| -rw-r--r-- | docs/src/en/reference/commands/lc/status.md | 6 | ||||
| -rw-r--r-- | docs/src/guide/admin/configuration.md | 48 | ||||
| -rw-r--r-- | docs/src/guide/admin/velocity.md | 10 | ||||
| -rw-r--r-- | docs/src/index.md | 2 | ||||
| -rw-r--r-- | docs/src/reference/commands/lc/settings.md | 9 | ||||
| -rw-r--r-- | docs/src/reference/commands/lc/status.md | 6 | ||||
| -rw-r--r-- | platform-paper/src/main/kotlin/dev/m1sk9/lunaticChat/paper/listener/PlayerChatListener.kt | 1 |
14 files changed, 132 insertions, 26 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md index 6316a1e..892cf86 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,7 @@ ### v0.8.0 - Velocity integration is now available. +- Fixed the header design for certain commands such as `/lc channel`. ### v0.7.0 diff --git a/docs/.vitepress/config/en.ts b/docs/.vitepress/config/en.ts index d5f4dd6..1669fbb 100644 --- a/docs/.vitepress/config/en.ts +++ b/docs/.vitepress/config/en.ts @@ -130,7 +130,7 @@ export const en: DefaultTheme.Config = { text: '/lcv', items: [ { - text: '/lc status', + text: '/lcv status', link: '/en/reference/commands/lcv/status', }, ], diff --git a/docs/.vitepress/config/ja.ts b/docs/.vitepress/config/ja.ts index 2ee250e..0e3e467 100644 --- a/docs/.vitepress/config/ja.ts +++ b/docs/.vitepress/config/ja.ts @@ -130,8 +130,8 @@ export const ja: DefaultTheme.Config = { text: '/lcv', items: [ { - text: '/lc status', - link: '/en/reference/commands/lcv/status', + text: '/lcv status', + link: '/reference/commands/lcv/status', }, ], }, diff --git a/docs/src/en/guide/admin/configuration.md b/docs/src/en/guide/admin/configuration.md index ef33ddc..15c8f10 100644 --- a/docs/src/en/guide/admin/configuration.md +++ b/docs/src/en/guide/admin/configuration.md @@ -68,6 +68,19 @@ features: retentionDays: 30 # Maximum size of a single log file in megabytes. Files exceeding this size will stop accepting new entries. maxFileSizeMB: 100 + velocityIntegration: + # If enabled, enables integration with Velocity proxy plugin. + # This allows Paper and Velocity instances to communicate and verify compatibility. + enabled: false + # If enabled, global chat messages will be shared across all Paper servers connected to the Velocity proxy. + # Players on different servers can communicate through the GLOBAL chat mode. + crossServerGlobalChat: false + # Server name to display in cross-server chat (e.g., "survival", "creative", "lobby"). + # This should match the server name defined in your Velocity configuration. + serverName: "Unknown" + # Size of the message deduplication cache to prevent duplicate messages from appearing. + # Keeps track of the most recent N message IDs to filter out duplicates. + messageDeduplicationCacheSize: 100 # ---------------------------------------------- # --------- Message Format Settings -------- @@ -80,6 +93,7 @@ features: # {recipient} - The name of the message recipient # {message} - The content of the message # {channel} - The name of the chat channel (only for channel chat) +# {server} - The name of the server (only for Velocity cross-server chat) # ---------------------------------------------- messageFormat: @@ -87,6 +101,8 @@ messageFormat: directMessageFormat: "§7[§e{sender} §7>> §e{recipient}§7] §f{message}" # Configure the format for messages sent in channel chat channelMessageFormat: "§7[§b#{channel}§7] §e{sender}: §f{message}" + # Configure the format for global chat messages in Velocity integration + crossServerGlobalChatFormat: "§7[§6{server}§7] §e{sender}: §f{message}" ``` ## General Settings @@ -246,6 +262,38 @@ Specifies the maximum size (in megabytes) of channel chat log files. Log files exceeding `maxFileSizeMB` will stop accepting new entries. +### `features.velocityIntegration` + +#### `enabled` + +- Type: `boolean` +- Default: `false` + +Enables integration with Velocity proxy plugin. + +#### `crossServerGlobalChat` + +- Type: `boolean` +- Default: `false` + +Specifies whether to share chat messages across all Paper servers connected to the Velocity proxy. + +#### `serverName` + +- Type: `string` +- Default: `Unknown` + +Specifies the server name to display in Velocity cross-server chat. + +Examples: `survival`, `creative`, `lobby` + +#### `messageDeduplicationCacheSize` + +- Type: `integer` +- Default: `100` + +Specifies the size of the message deduplication cache. + ## Message Format Settings Available placeholders: @@ -254,6 +302,7 @@ Available placeholders: - `{recipient}`: Name of the message recipient - `{message}`: Content of the message - `{channel}`: Name of the chat channel (only for channel chat) +- `{server}`: Name of the server (only for Velocity cross-server chat) ### `messageFormat.directMessageFormat` @@ -268,3 +317,10 @@ Specifies the format for messages sent via direct message ([`/tell`](../../refer - Default: `§7[§b#{channel}§7] §e{sender}: §f{message}` Specifies the format for messages sent in channel chat. + +### `messageFormat.crossServerGlobalChatFormat` + +- Type: `string` +- Default: `§7[§6{server}§7] §e{sender}: §f{message}` + +Specifies the format for messages sent via Velocity cross-server global chat. diff --git a/docs/src/en/guide/admin/velocity.md b/docs/src/en/guide/admin/velocity.md index 9b4f10e..6a4e6f7 100644 --- a/docs/src/en/guide/admin/velocity.md +++ b/docs/src/en/guide/admin/velocity.md @@ -76,6 +76,6 @@ The main features available during Velocity integration are as follows: | | Compatibility | Behavior | Notes | |------------| --- | --- | --- | -| Direct Messages | ◯ | Can send DMs to players on other servers using `/tell` and `/reply` commands | | +| Direct Messages | × | `/tell` and `/reply` commands operate only within the server | Direct messages do not support Velocity integration. | | Channel Chat | × | Channel chat operates only within the server | Channel chat does not support Velocity integration. | | Kana/Romanization | ◯ | Kana/Romanization works across all servers | | diff --git a/docs/src/en/index.md b/docs/src/en/index.md index 0fe8a53..266c4a6 100644 --- a/docs/src/en/index.md +++ b/docs/src/en/index.md @@ -32,10 +32,10 @@ features: - title: Japanese Romanization Conversion details: Automatically converts messages input in romaji to Japanese icon: 🌍 - - title: Channel Chat Feature (Planned) + - title: Channel Chat Feature details: Create and manage chat channels, send private messages between specific players icon: ☎️ - - title: Multi-Platform Support (Planned) + - title: Multi-Platform Support details: Support for multi-platform Paper and Velocity, enabling cross-server chat icon: 🚀 - title: High-Speed Performance with Caching diff --git a/docs/src/en/reference/commands/lc/settings.md b/docs/src/en/reference/commands/lc/settings.md index 4d09301..8b88066 100644 --- a/docs/src/en/reference/commands/lc/settings.md +++ b/docs/src/en/reference/commands/lc/settings.md @@ -2,9 +2,9 @@ ### `/lc settings <key> [value]` -| Permission | -|--------------------------------| -| `lunaticchat.command.settings` | +| Permission | +|-----------------------------------| +| `lunaticchat.command.lc.settings` | Manages player settings for LunaticChat. If no value is specified, the current setting value will be displayed. @@ -16,3 +16,4 @@ This setting is saved by UUID, so the setting will not be lost even if you chang |----------|----------------------------------------------------------|--------| | `japanese` | Toggles romanization conversion on or off. | `true` | | `notice` | Toggles whether to receive notifications when receiving direct messages via `/tell` or `/reply`. | `true` | +| `chNotice` | Toggles whether to receive notifications when receiving channel chat messages. | `true` | diff --git a/docs/src/en/reference/commands/lc/status.md b/docs/src/en/reference/commands/lc/status.md index 365519a..1fa6a39 100644 --- a/docs/src/en/reference/commands/lc/status.md +++ b/docs/src/en/reference/commands/lc/status.md @@ -2,8 +2,8 @@ ### `/lc status` -| Permission | -|------------------------------| -| `lunaticchat.command.status` | +| Permission | +|---------------------------------| +| `lunaticchat.command.lc.status` | Displays the status of LunaticChat. diff --git a/docs/src/guide/admin/configuration.md b/docs/src/guide/admin/configuration.md index 5eb5fc6..b641549 100644 --- a/docs/src/guide/admin/configuration.md +++ b/docs/src/guide/admin/configuration.md @@ -68,6 +68,19 @@ features: retentionDays: 30 # Maximum size of a single log file in megabytes. Files exceeding this size will stop accepting new entries. maxFileSizeMB: 100 + velocityIntegration: + # If enabled, enables integration with Velocity proxy plugin. + # This allows Paper and Velocity instances to communicate and verify compatibility. + enabled: false + # If enabled, global chat messages will be shared across all Paper servers connected to the Velocity proxy. + # Players on different servers can communicate through the GLOBAL chat mode. + crossServerGlobalChat: false + # Server name to display in cross-server chat (e.g., "survival", "creative", "lobby"). + # This should match the server name defined in your Velocity configuration. + serverName: "Unknown" + # Size of the message deduplication cache to prevent duplicate messages from appearing. + # Keeps track of the most recent N message IDs to filter out duplicates. + messageDeduplicationCacheSize: 100 # ---------------------------------------------- # --------- Message Format Settings -------- @@ -80,6 +93,7 @@ features: # {recipient} - The name of the message recipient # {message} - The content of the message # {channel} - The name of the chat channel (only for channel chat) +# {server} - The name of the server (only for Velocity cross-server chat) # ---------------------------------------------- messageFormat: @@ -87,6 +101,8 @@ messageFormat: directMessageFormat: "§7[§e{sender} §7>> §e{recipient}§7] §f{message}" # Configure the format for messages sent in channel chat channelMessageFormat: "§7[§b#{channel}§7] §e{sender}: §f{message}" + # Configure the format for global chat messages in Velocity integration + crossServerGlobalChatFormat: "§7[§6{server}§7] §e{sender}: §f{message}" ``` ## General Settings @@ -246,6 +262,38 @@ LunaticChat の [`/reply`](../../reference/commands/reply.md) コマンドによ `maxFileSizeMB` を超えたログファイルは新しいエントリを受け付けなくなります. +### `features.velocityIntegration` + +#### `enabled` + +- Type: `boolean` +- Default: `false` + +Velocity プロキシプラグインとの連携を有効にします. + +#### `crossServerGlobalChat` + +- Type: `boolean` +- Default: `false` + +Velocity プロキシに接続されたすべての Paper サーバー間でチャットメッセージを共有するかどうかを指定します. + +#### `serverName` + +- Type: `string` +- Default: `Unknown` + +Velocity クロスサーバーチャットで表示されるサーバー名を指定します. + +例: `survival`, `creative`, `lobby` + +#### `messageDeduplicationCacheSize` + +- Type: `integer` +- Default: `100` + +メッセージの重複排除キャッシュのサイズを指定します. + ## Message Format Settings 使用できるプレースホルダー: diff --git a/docs/src/guide/admin/velocity.md b/docs/src/guide/admin/velocity.md index 98f5a6f..d6de2c6 100644 --- a/docs/src/guide/admin/velocity.md +++ b/docs/src/guide/admin/velocity.md @@ -74,8 +74,8 @@ Velocity 連携が有効化されている場合,プロキシサーバーを Velocity 連携中に利用可能な主な機能は以下の通りです: -| | 互換性の有無 | 挙動 | 備考 | -|------------| --- | --- | --- | -| ダイレクトメッセージ | ◯ | `/tell`, `/reply` コマンドで他サーバーのプレイヤーに DM を送信可能 | | -| チャンネルチャット | × | チャンネルチャットはサーバー内限定で動作 | チャンネルチャットは Velocity 連携に対応していません. | -| かな・ローマ字変換 | ◯ | かな・ローマ字変換は全サーバーで動作 | | +| | 互換性の有無 | 挙動 | 備考 | +|------------|--------|-----------------------------------|-----------------------------------| +| ダイレクトメッセージ | × | `/tell`, `/reply` コマンドはサーバー内限定で動作 | ダイレクトメッセージは Velocity 連携に対応していません. | +| チャンネルチャット | × | チャンネルチャットはサーバー内限定で動作 | チャンネルチャットは Velocity 連携に対応していません. | +| かな・ローマ字変換 | ◯ | かな・ローマ字変換は全サーバーで動作 | | diff --git a/docs/src/index.md b/docs/src/index.md index c3410cb..abdf453 100644 --- a/docs/src/index.md +++ b/docs/src/index.md @@ -35,7 +35,7 @@ features: - title: チャンネルチャット機能 details: チャットチャンネルを作成・管理し,特定のプレイヤー間でのプライベートメッセージを送信可能 icon: ☎️ - - title: マルチプラットフォーム対応 (実装予定) + - title: マルチプラットフォーム対応 details: Paper と Velocity のマルチプラットフォームに対応し,サーバ間チャットを実現します icon: 🚀 - title: キャッシュによる高速動作 diff --git a/docs/src/reference/commands/lc/settings.md b/docs/src/reference/commands/lc/settings.md index ab595ef..d9b59db 100644 --- a/docs/src/reference/commands/lc/settings.md +++ b/docs/src/reference/commands/lc/settings.md @@ -2,9 +2,9 @@ ### `/lc settings <key> [value]` -| パーミッション | -|--------------------------------| -| `lunaticchat.command.settings` | +| パーミッション | +|-----------------------------------| +| `lunaticchat.command.lc.settings` | LunaticChat のプレイヤー設定を管理します.値を指定しなかった場合は設定値が表示されます. @@ -15,4 +15,5 @@ LunaticChat のプレイヤー設定を管理します.値を指定しなか | キー | 説明 | デフォルト値 | |------------|----------------------------------------------------------|--------| | `japanese` | ローマ字変換の有効化・無効化を切り替えます. | `true` | -| `notice` | `/tell` や `/reply` でダイレクトメッセージを受信した際に通知を受け取るかどうかを切り替えます. | `true` | +| `notice` | `/tell` や `/reply` でダイレクトメッセージを受信した際に通知を受け取るかどうかを切り替えます. | `true` | +| `chNotice` | チャンネルチャットを受信した際に通知を受け取るかどうかを切り替えます. | `true` | diff --git a/docs/src/reference/commands/lc/status.md b/docs/src/reference/commands/lc/status.md index 1b9ddcb..997d0ac 100644 --- a/docs/src/reference/commands/lc/status.md +++ b/docs/src/reference/commands/lc/status.md @@ -2,8 +2,8 @@ ### `/lc status` -| パーミッション | -|------------------------------| -| `lunaticchat.command.status` | +| パーミッション | +|---------------------------------| +| `lunaticchat.command.lc.status` | LunaticChat のステータスを表示します. diff --git a/platform-paper/src/main/kotlin/dev/m1sk9/lunaticChat/paper/listener/PlayerChatListener.kt b/platform-paper/src/main/kotlin/dev/m1sk9/lunaticChat/paper/listener/PlayerChatListener.kt index ec8c58e..c17dba2 100644 --- a/platform-paper/src/main/kotlin/dev/m1sk9/lunaticChat/paper/listener/PlayerChatListener.kt +++ b/platform-paper/src/main/kotlin/dev/m1sk9/lunaticChat/paper/listener/PlayerChatListener.kt @@ -7,7 +7,6 @@ import dev.m1sk9.lunaticChat.paper.chat.handler.ChannelMessageHandler import dev.m1sk9.lunaticChat.paper.config.LunaticChatConfiguration import dev.m1sk9.lunaticChat.paper.converter.RomanjiConverter import dev.m1sk9.lunaticChat.paper.i18n.LanguageManager -import dev.m1sk9.lunaticChat.paper.i18n.MessageFormatter import dev.m1sk9.lunaticChat.paper.settings.PlayerSettingsManager import dev.m1sk9.lunaticChat.paper.velocity.CrossServerChatManager import io.papermc.paper.event.player.AsyncChatEvent |
