MineCord

插件

· 作者 BasedKyle

一个专为聊天设计的 Minecraft Paper 和 Folia 插件,支持与 Discord 集成。

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

最新 0.3.1-alpha · 26.2 · Folia / Paper

一键开服(送7天)

? MineCord

MineCord 是一款现代且高效的 Minecraft 插件。它将游戏内聊天拆分为本地和全局频道,并确保全局聊天与你的 Discord 服务器同步。该插件支持 Paper 和多线程的 Folia 核心。

  • ? 聊天分割: 玩家通过以 "!"(或其他符号)为前缀来发送消息,从而在本地聊天(仅附近可见)或全局聊天(对服务器所有玩家可见)中进行交流。
  • ? 双向 Discord 集成: 来自全局聊天的消息会即时转发到指定的 Discord 频道。在 Discord 上发布到该频道的消息也会直接广播到游戏中。
  • ? 自定义: 你可以调整本地聊天半径、全局聊天符号,以及消息前缀和颜色(支持与经典颜色代码 '& '配合使用)。
  • ? 支持 Folia 和 Paper

? 安装

  • 下载 .jar 文件并将其放入服务器的 plugins 文件夹中。
  • 启动服务器一次,然后停止它(或等待出现 "Token not configured" 消息)。

如果你需要 Discord 集成:

Spoiler
  • 访问 Discord Developers Portal 并创建一个新的机器人。
  • 在 "Bot" 选项卡上,向下滚动并确保启用 "Message Content Intent" 开关。
  • 转到 OAuth2 选项卡,勾选 "bot" 框,并授予机器人 "Send Messages" 权限。将机器人邀请到你的服务器。
  • 复制机器人的 Token 以及它应该发布消息的频道的 ID。

如果你想使用 Webhook(在 Discord 中显示玩家的昵称和头像):

Spoiler

Discord 频道设置 -> 集成 -> Webhooks -> 创建 Webhook -> 复制 URL

  • 打开服务器上的 plugins/MineCord/config.yml 文件,并将 Token、频道 ID 和 Webhook URL 粘贴到相应的字段中。你也可以配置任何你需要的内容。
  • 启动服务器。你应该在控制台中看到一条消息:"The Discord bot has successfully connected!"(如果你已配置了集成)

?️ 配置 (config.yml)

你可以根据项目的风格对其进行自定义:

discord:
  # "bot" - 使用机器人
  # "webhook" - 使用 Webhook
  type: "webhook"

  # 如果你想实现 Discord -> Minecraft 聊天 // 如果使用 "bot" 模式
  token: "token"
  channel_id: "channel id"

  # 如果使用 "webhook"
  webhook_url: "url"

  # 头像 API
  avatar_url_template: "https://mc-heads.net/avatar/%uuid%"

chat:
  global-symbol: "!"

  local:
    radius: 200
    format: "&8[&7Local&8] &f%player%&8: &7%message%"

  global:
    format: "&8[&eGlobal&8] &f%player%&8: &e%message%"

  discord-to-minecraft:
    format: "&9[Discord] &f%player%&8: &b%message%"

messages:
  global-disabled: "&cYou have disabled the global chat."
  global-enabled: "&aYou have enabled the global chat."
  discord-disabled: "&cYou have disabled the Discord chat."
  discord-enabled: "&aYou have enabled the  Discord chat."
  ignore-add: "&cYou have added player %player% to your ignore list."
  ignore-remove: "&aYou have removed player %player% from your ignore list."
  ignore-self: "&cYou cannot ignore yourself!"
  player-not-found: "&cPlayer not found or is offline."

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

评论 0

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

登录后参与评分

还没有评论,来抢沙发吧

评论配图

相似资源